Review: Touch the Button

In the info section of the orientation, the game “touch the button 15 times” had a very basic problem - no matter what, when the game was over, the same screen was shown, with the only difference being the score.

This can be changed using two using two blocks: on life zero and on countdown end. These blocks are used to override (change) the standard behavior for running out of lives and time running out for a countdown.

Touch the Button

Initial Game:

2-1change life bychange score byonAbuttonpressed152start countdown(s)set life toon start

Student Task #1: Using on countdown end

Modify the behavior of the countdown ending to add a penalty for running out of time.

  1. Add in the on countdown end block
  2. Inside the on countdown end block, use the change score by block to subtract 10 points from the score
  3. After subtracting 10 from the score in the on countdown end, use the game over block to end the game

Student Task #2: Using on life zero

Give the player a bonus when they touch the button enough, and then continue the game.

  1. Add in the on life zero block
  2. Add in a stop countdown block into the on life zero block to end the countdown
  3. Add a splash screen after the countdown is stopped that tells the player that they are moving onto the next level
  4. Copy the two blocks from the on start block into the on life zero block after the splash, so that the lives and countdown both ‘reset’
  5. Use the set score to block to set the score to two times the current score in the on life zero block using the x and score blocks