Noob requires help!

Please help me. I am a 10 year old noob that requires assistance. One of the sample games is a 3D roller coaster and when you use it the game would be paused and the text “tap to begin” would appear. You would then of course tap to start. How was this done and how can I replicate this?
ps.Codea is really nice but it it is not really noob friendly because the reference expects you to know where and how exactly you want to do the command or function so I have to guess


Look in the Main class for the code. The basic premise is that you have a Boolean (one that can only be one of two states, either true or false) variable and you swap the value when the screen is pressed.

So starting off, paused = true

**The main program checks to see the value of the paused variable.
If it is true then it prints the message" the game is paused"
If it is false, it runs the program ( in this case the roller coaster)

It then checks to see if the screen has been touched.
If it has then it swaps the value of paused. So if paused is true it sets it to false. If paused is false it sets it to true.

It then goes loops back to ** above.

Also check out reef wings tutorial on finite state machines for a better overview of controlling game states ( for example if you want a program that has more than two states)