Our online Scratch coding courses are an ideal way to experience our lessons at home. Try a free lesson.
£24.99 or less
In this exercise you will learn how to make the Cat walk with keyboard key presses.
NOTE: You can use any version of Scratch.
Complete these steps ..
1. Open Scratch, OR create a new game (from the top menu choose "File>New").
2. Re-name the cat sprite "Cat" ..
3. Click the "only face left right" button ..
If you are using Scratch desktop add this code ..
4. Now let's add the scripts/code so we can make the Cat walk. Look at the image below and copy the 4 scripts to make the Cat walk ..
Press the arrow keys on your keyboard to test your scripts.
5. The scripts/code are a bit slow and glitchy. Let's make some better ones.
Delete the four key pressed scripts by dragging them left off the code/scripting area ..
6. We need a script to end the game. Add this script/code ..
7. Replace the scripts/code you have deleted with these better one ..
Press the "B" key to start the game and then try out the arrow keys.
When you are ready, press the "E" key to end your game.
8. Use the File menu to save your game. Name it "Arrow keys control v1".
9. Well done! You've finished this exercise.