Project 113: Finger Dancing

4. Gain points when the player hits the right key

The player should gain 2 points if they press the correct arrow key at the same time that clone is touching the Goodbar, then delete the clone.
Starting point file for this challenge

Your goal

Steps

1. Set up the code to check if two things are true at the same time

Inside the forever loop created in step 3, add an "if __ then" block. 
To check if two things are true at the same time you’ll need to use the "__ and __" block from the green "Operators" section.

2. Check if the clone is touching the Goodbar and the correct arrow key is pressed

Add light blue sensing blocks inside of the "__ and __" to check if the arrow key is pressed at the right time. 

3. Gain 2 points

Change the score variable by 2.

4. Delete the clone

Once the game has registered the point gained, the clone is no longer necessary, so we can delete it.