Your task is to create a game in Greenfoot, with three types of elements: a PLAYER object,
controlled by the player; FOOD objects that can be ‘caught’ by the player; and ENEMY objects,
that can ‘catch’ the player. If the enemy catches the player, then the game is over.
You must create a new scenario and you must choose a theme for your game that is not
crabs/worms and lobsters. All your elements should suit your theme, including the background
and the actors. The movement of the actors should ‘make sense’ as per the theme of your game.
We do not expect to see the same theme or game created by any two students – be original!
• You will create a Player class.
• At the beginning of the game, there must be one PLAYER object on the screen.
• The PLAYER must be controlled by the keyboard, and at minimum must move
automatically and have left and right turn. For example, when the left arrow key on the
keyboard is pressed, the PLAYER will turn to the left while moving forwards. When the
right arrow key is pressed, the PLAYER will turn to the right while moving forward.
• You will create one Food class.
• There must be eight FOOD objects on the screen at the beginning of the game.
• Each FOOD object must have random movement on the screen – that is, it must turn in
random directions and move at a random speed. The food must be able to be caught by
• When the FOOD is caught by the PLAYER, it should be removed from the screen.
• Later in the Portfolio, you will use the Food class to create different types of Food objects
so you will need to think about the theme for your food carefully.