際際滷

際際滷Share a Scribd company logo
Scratch Part 4  Moving Around the Maze
What you are going to do. In this presentation you will learn how to make your character move around a maze without walking through walls.
Step 1  Click on your sprite
Step 2  Go to scripts
Step 3  Go to Control
Step 4  Drag If before the stop script block for up arrow
Step 5  Go to motion
Step 6  Drag Move 10 steps in if block
Step 7  set steps to -10
Step 9  Go to Sensing
Step 10  Drag touching colour into the if block
Step 11  Set touching colour to you maze wall colour
Step 12  Repeat task 1-11 for other movement blocks You are now going make your character stop at walls when moving in all directions. Using the instructions from step 1 -11 you can add the same code to each of the direction blocks.
Step 13  Check your work is correct
Step 14  Save your work Save your work You have now created a character that can move around your maze well done

More Related Content

Scratch part 4 moving around the maze

  • 1. Scratch Part 4 Moving Around the Maze
  • 2. What you are going to do. In this presentation you will learn how to make your character move around a maze without walking through walls.
  • 3. Step 1 Click on your sprite
  • 4. Step 2 Go to scripts
  • 5. Step 3 Go to Control
  • 6. Step 4 Drag If before the stop script block for up arrow
  • 7. Step 5 Go to motion
  • 8. Step 6 Drag Move 10 steps in if block
  • 9. Step 7 set steps to -10
  • 10. Step 9 Go to Sensing
  • 11. Step 10 Drag touching colour into the if block
  • 12. Step 11 Set touching colour to you maze wall colour
  • 13. Step 12 Repeat task 1-11 for other movement blocks You are now going make your character stop at walls when moving in all directions. Using the instructions from step 1 -11 you can add the same code to each of the direction blocks.
  • 14. Step 13 Check your work is correct
  • 15. Step 14 Save your work Save your work You have now created a character that can move around your maze well done