Collision detection exercise, Hannah Dee
2. A steerable player box with mouse and touch events
This canvas has some boxes, and you have to write the "collides" function which determines when they overlap
- Study the code carefully - this time the canvas responds to mouse events and to touch events
- If there are things that don't make sense, just ask.
- Create an array of boxes that appear on the screen when start_game() is called
- Steer the player box into and around the other boxes
- Try drawing some images instead of boxes
Total collisions so far: