First

Started by metalmario991, Sun 18/01/2015 03:40:54

Previous topic - Next topic

metalmario991

How do I make it so an event happens only the first time you do it?

monkey424

Quote from: metalmario991 on Sun 18/01/2015 03:40:54
How do I make it so an event happens only the first time you do it?

Depends what event it is.

If the event is walking into a room, use function room_FirstLoad().

If the event is something else, say clicking on a hot spot, then declare a boolean variable with an initial state of 0, and set it to 1 once the event has happened. Only run the event on the condition that the variable is 0.

Good luck!
    

monkey0506

Game.DoOnceOnly, followed by RTFM.


I wasn't going to, but with a thread title like that...

SMF spam blocked by CleanTalk