For this assignment, you will create a Pacman-like game in which the player uses the keyboard to control the character. The player gains points by capturing food pellets while avoiding an computer ghost. If the ghost touches the player, then the ghost respawns elsewhere on the screen but the player’s point total resets. In addition to AI, The assignment will introduce keyboard events and collision detection.
[swf]http://mrkam.ca/wordpress/wp-content/uploads/Pacman.swf, 550, 400[/swf]
Evaluation: The game is marked out of 10 based on the following criteria:
- Does the keyboard control Pacman (no diagonal)?
- Does Pacman only stay inside the stage?
- Is Pacman animated facing the correct direction with chomping motion?
- Does the ghost move and stay inside the stage?
- Does the ghost follow in Pacman’s general direction?
- Does the speed increase proportional to the score?
- Does capturing a food pellet increase score by 1?
- Does the food pellet respawn at a random location when player touches it?
- Does the score reset when player touches ghost?
- Does the ghost respawn at a random location when the player touches it?