(PUDG) Creating a Scenario Lesson

Creating a Scenario

To create a game in Greenfoot, you will need to create a scenario from scratch. The scenario will contain all the source code, sound and images that make up the game.

Download the Flappy Bird resources from the sidebar. This folder contains the assets (images and sounds) you need for the project.  

How to Create a Scenario in Greenfoot

Syntax Rules for Creating Classes in Java

  • Class names start with a capital letter and have no spaces. If the name is two words, use camel case. Capitalize the first letter of each word.     FlyingBird
  • Class names start with a letter. The symbols _ and $ are the only symbols allowed in the file name. Basic Syntax of a Java Program.

Flying Bird World Assignment

Download the Flappy Bird resources FROM THIS LINK. This folder contains the assets (images and sounds) you need for the project. Links to an external site.

  1. Create a new scenario called flyingbirdWorld.  
  2. Add the assets from the Flying_World_Assets folder to the images folder in the flyingbirdWorld Greenfoot folder.  
  3. Create the following classes and select the correct images for the class.

World classes
World
FlyingBirdWorld

Actor classes:
Actor
SharedResources
Ground
Bird1
Top Pipe
Bottom Pipe

[CC BY 4.0] UNLESS OTHERWISE NOTED | IMAGES: LICENSED AND USED ACCORDING TO TERMS OF SUBSCRIPTION