Step 2

Arranging the finish line blocks

First we need to get physics disabled on the finish line so that it doesn't block the player from getting past. Grab "Set physics enabled to false" and put it inside the "When created" block.

Then we need to get the Constantly loop working to detect if the player has gone past the finish line. We'll check if the x position of the player is greater than x position of myself. Grab the "if" block and put it inside the "Constantly" block. Then grab the "=" block from Operators, and drag it into the if block. Click on the = to change it to >.

Then grab the "x position of myself" block from Transform, and place two of that block on either side of the >. Get rid of the "myself" block from the "x position" block on the right. Grab the "first instance by tag" block from Sensing, and drag it into where the "myself" block was.

Grab the "go to next level" block (from Control Flow) and drag it inside the "if" block.

results matching ""

    No results matching ""