Page 5: Improving Your Game

Unit 1, Lab 1, Page 5

There’s always something more you can do to make a program better. On this page, you’ll improve your game by making Alonzo welcome the player when the green flag (green-flag button) is clicked.

  1. If your project is open and the script is still running, click the red stop sign, red stop button. If it isn’t open already, open your U1L1-ClickAlonzo project.

Clicking the green flag button in the top right corner of the window (green-flag button) starts all scripts that begin with the when green flag clicked hat block.
a yellow round-topped hat block that says When 'picture of a green flag' is clicked

  1. Create a second script that makes Alonzo say () a welcome message when the green flag is clicked. (Alonzo might say, “Welcome to ‘Click Alonzo!’ Keep clicking me if you can!”)

  2. Make that message disappear when the player clicks on Alonzo.

The say block with an empty text in the white input slot will make the sprite say nothing.

  1. Check that your app does everything you want:

    • When the green flag is clicked, Alonzo should welcome the player.
    • When Alonzo is clicked, the message should disappear, and Alonzo should move to a random spot on the stage, face the other way, and get more transparent.
    • Alonzo should start to reappear (but shouldn’t face the other way) any time he moves without being clicked.
  2. Save your work