Homework
For this homework, you are going to alter your spore-like game by defining functions and calling them in your draw method or within other functions. Again, don’t worry about collisions.
Here is an example for Homework 12.
p>Homework Walkthrough Video</p>
Specifications
- Create a function that creates a player.
- Create a function to move the player using the keyboard.
- Create a function that draws the circle to the screen when pressing the mouse.
- Create a function that creates multiple obstacles of different sizes and colors on the screen (okay if you still have only 2).
- Create different functions to move each of the obstacles around randomly around the screen. If they leave the screen, have them come back on the other side.
- Create a function to generate the borders and the exit
- Create a function to display the “You win” message.
- If the player gets to the exit, call the “you win” function.
- Your draw() function should contain only function calls along with the background function.
- Ignore all collisions.
- Complete the Kahoot Challenge, take a screenshot and upload it to your repository.
- Submit your repository link to Moodle.