In this lesson we will create a shark tank game. You will control a shark using the arrow keys on your keyboard and make the shark chase other sea creatures!
Create a new Scratch project and delete the cat sprite by right clicking on the cat and then clicking on the 'delete' option in the menu that appears.
First let's add an underwater backdrop to our project from the backdrop library. Follow these steps to add in an underwater backdrop:
You can filter the backdrops in the library by clicking on any of the Category or Theme links.
Children will need to get used to using the scroll bar to scroll down to find a particular backdrop or sprite.
Now let's add a fish sprite from the sprite library. Follow these steps to add the fish sprite:
You can filter the sprites in the library by clicking on any of the Category or Theme links.
Now add a shark sprite from the sprite library. Follow these steps to add the shark sprite:
Now let's program the fish to swim around the tank. We'll also give the fish some instructions to shrink a little bit.
Click on the fish sprite in the sprite list (below the stage area) and then add the following code to the fish:
Next we will program the fish to disappear if the shark touches it! Add the following code to the fish:
We use the looks show block so that when we click the green flag to start a new game, the fish will appear again.
We use the motion set rotation style [left-right] block so that the fish doesn't rotate and appear upside down when it's swimming left and right.