
Try Dinosaur Leaf Pile Play for fun Scratch Project!
Dinosaur Leaf Pile Play
Platform: Scratch
Level: intermediate
In this project, the two dinosaurs can clone themselves to create multiple leaf piles in the woods. As they approach a leaf pile, they can use messaging to send a signal that they are ready to play with it. When they play, a variable can track the score of how many leaves they each toss into the air. The project can include animations for tossing leaves and celebrating together.
Backdrop And Sprite Images For The Project



Dinosaur Leaf Pile Play: Solution Outline
These are the high level steps to create this project. Try to create the project on your own first as much as possible, before checking the detailed solution samples below.
- Create the dinosaur characters and leaf pile sprites.
- Program the dinosaurs to clone leaf piles.
- Set up messaging for interaction with leaf piles.
- Animate the dinosaurs tossing leaves and track score.
- Celebrate when a score milestone is reached.
Dinosaur Leaf Pile Play Sample Solutions
This section provides detailed, step-by-step instructions on how to build the project. There are many ways to create a project, so feel free to explore different approaches. Please note that these instructions are Al-generated, so errors may occur and the coding blocks may not map to Scratch exactly. But it should serve as very valuable references. Stay attentive as you follow along, and enjoy!
Start by creating or importing two dinosaur sprites and a leaf pile sprite. Position the dinosaurs on the stage and ensure they have costumes for animations like tossing leaves. The leaf pile sprite will be used for cloning.
Use the 'when green flag clicked' block to initialize the game. Then, use a loop to create clones of the leaf pile sprite at random positions on the stage. This can be done using the 'create clone of' block and setting random positions with 'go to x: (random position) y: (random position)'.
When a dinosaur sprite touches a leaf pile clone, it should send a message to indicate it's ready to play. Use the 'when I start as a clone' block for the leaf pile to detect touching a dinosaur and then broadcast a message like 'ready to play'.
Upon receiving the 'ready to play' message, animate the dinosaurs tossing leaves using costume changes and motion blocks. Increase a score variable each time a leaf is tossed. Use 'change [score v] by 1' to update the score.
Add a condition to check if the score reaches a certain number, then trigger a celebration animation for both dinosaurs. This can be done using a 'if [score v] = 10 then' block to start a celebration sequence.
Common Potential Issues in Dinosaur Leaf Pile Play Project
It is common to have bugs in the code. Here are some of issues you might run into.
- Ensuring clones are properly deleted after interaction to avoid clutter.
- Managing the timing of animations so they don't overlap or appear too fast.
- Making sure the score variable updates correctly and reflects the right player's actions.
Extra Challenges For Dinosaur Leaf Pile Play
- Add a timer to see how many leaves can be tossed in a limited time.
- Create different types of leaf piles that give different scores when played with.
Learn Scratch Coding Skills
Enroll your child in award-winning online Scratch coding classes led live by experts and designed by professionals from Google, Stanford, and MIT.
Grades K-2
Start coding with ScratchJr, and make interactive stories and gamesGrades 2-6
Code games and animations with beginner-friendly Scratch codingGrades 5-9
Fast-paced introduction to coding: build games, stories, and animationsGrades 3-6
Code a new fun Scratch game every weekExplore More Fun Scratch Practice
The challenge continues: Enjoy even more Scratch tutorials dreamed up by other students or use your imagination to make your own!
Find Best Classes For Your Child
Explore your child's grade level to find computer science classes and learning pathways that set your student up for success.