Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Preventing scripts from repeating
rybray Offline
Junior Member

Posts: 31
Threads: 9
Joined: Aug 2011
Reputation: 1
#5
RE: Preventing scripts from repeating

Im sorry to continue this, but I think I'm on the verge of understanding it. What I understand is that the variable is set to 0 on the starting of the map. then the function checks to see if the variable is 0, and if it is then the function is done, and on leaving the map, the variable is then set to 1, so that theoretically if the function was run again it would be stopped at the variable check.

So lets say that you exited that map through a level door and loaded up a new map with a new script, and then returned to the first map- wouldnt the onstart() function reset the variable to 0, therefore causing the function to run again?

I am very thankful for all of your replies.
(This post was last modified: 08-17-2011, 09:18 PM by rybray.)
08-17-2011, 09:12 PM
Find


Messages In This Thread
Preventing scripts from repeating - by rybray - 08-17-2011, 04:16 PM
RE: Preventing scripts from repeating - by Kyle - 08-17-2011, 04:30 PM
RE: Preventing scripts from repeating - by rybray - 08-17-2011, 05:46 PM
RE: Preventing scripts from repeating - by Kyle - 08-17-2011, 05:57 PM
RE: Preventing scripts from repeating - by rybray - 08-17-2011, 09:12 PM
RE: Preventing scripts from repeating - by Acies - 08-18-2011, 12:01 AM



Users browsing this thread: 1 Guest(s)