Page 1 of 1

a few questions

PostPosted: Tue Aug 04, 2009 4:12 pm
by Fojam
how do you do the if variable = 1 script setup?

is there a code to reset the game?

Re: if variable = 1

PostPosted: Tue Aug 04, 2009 6:26 pm
by Rux
Code: Select all
if(variable == 1)
{
//insert code here\\
}


Here.

Re: if variable = 1

PostPosted: Wed Aug 05, 2009 8:53 am
by Fuzzy
Dont forget. You need two = not just one. Rux' code shows it correctly.

Re: a few questions

PostPosted: Mon Aug 24, 2009 9:09 pm
by Fojam
well how do I completely restart the game by hitting a button or something?

Re: a few questions

PostPosted: Mon Aug 24, 2009 10:08 pm
by skydereign
You can reload the game, as in use the LoadGame function. This won't work if you are using tiles. You can also store all beginning positions, or similar, and reset all of them through use of a timer or variable. This is how you use the LoadGame function.
Code: Select all
LoadGame("gamePath");