This screenshot shows the beginning of the design. This is where you select your objects/characters that will be needed for the game. At the beginning of this design, I had only selected 3 of the characters/objects shown. Along the way, I added the necessary objects needed for the final design of the game.
|
The crocodile in this design was used as a tool to create the background setting. This was done by selecting an object (the crocodile), and making it invisible. After this, I used a code to set the background colour that would appear as soon as the play button is pressed.
|
This speed was set so that the background would appear quickly when the play button was selected. This way, the game is started straight away and there is no waiting for the background to appear.
|
The main character in this game is required to complete a number of activities throughout the game. In this code, you can see that the character was placed in a set position from the beginning of the game, and changes when the screen or mouse is pressed. When the screen is pressed, the character has been programmed to jump up and down to avoid the cactus. The character has also been programmed to flip when jumping over the cactus.
The above screenshot shows two of the objects that were placed in the background to make the game more appealing. The codes for each object show that they have been placed in a set position and have also been enlarged to make the more visible.
|
The second part of the coding for this character is the action that takes place when the character bumps into the cactus. She has been programmed to disappear and make a buzzing noise.
This is another code that has been used to set the position of the butterfly in the background of the game. This is a simple code but is all that is needed to set a position for any object.
|
The next step was to make a code for the cactus, the object to avoid in the game. The first code sets a specific position for the cactus. The next code is an algorithm that explains how the cactus will move throughout the game. This code make the cactus move along the screen with enough time in between each one so that the character can jump over it successfully.
Above is the final design for the game. After all of the codes had been created and the play button has been pressed, this is what the screen on the device will look like. Once the screen in tapped, the objects will begin moving and the game has begun.
|
|
This video shows the game being played once all of the codes had been finalised.
|