Step 1: Setting Up Our Variables

Goal:


Let’s start by making variables.

Variables are something computers use to store information so that it can be used later in our code.

The “Lives:” variable will be used to keep track of how many lives are left.

The “Points:” variable will be used to keep track of the current score in the game.

The “High Score:” variable will be used to keep track of the current best score.

Steps:

  1. From Variables click on Make a Variable to make 3 different variables.
  2. Name these variables “Lives:”, “Points:” and “High Score:”.

Code:


Click to replay