BlocosIA Wiki Editor

Click game: points and time

Medium · A full game: the sprite runs away when clicked, you score points and time runs out in 20 seconds.

Interactive tutorial: the editor checks each step by itself.

  1. Choose a sprite. It will run away from you!
  2. Open Variables and click "Make a variable". Name it "points".
  3. Drag "when green flag clicked" (Events) and snap "set points to 0" below.
  4. In Sensing, also snap "reset timer" below the flag.
  5. Make another script: "when this sprite clicked" (Events).
  6. Below it, snap "change points by 1" (Variables).
  7. Also snap "go to random position" (Motion): it runs away!
  8. In the flag script, add a "forever" (Control) and an "if … then" inside it.
  9. In the "if" slot, put "… > 50" (Operators) with "timer" (Sensing) on the left and 20 on the right.
  10. Inside the "if", snap "say Hello! for 2 seconds" and then "stop all" (Control).
  11. Click the flag and try to score many points in 20 seconds!
  12. Challenge: show the points at the end by replacing "Hello!" with "join Points: with points" (Operators). (challenge)

Open in the editor