MrJolteon wrote:Wertyboy wrote:jonathang wrote:Put shining lights around the disco rocket,and its perfect! Its nice so far though! For the awesome game,+1!
What do u call the 2nd rocket? xD
Thx, What do i call it? NyaStaditiontro Rocket... i guess
K guys i got a question, do we allow to write a script like this one?
- Code: Select all
if(topitem=7;bodyitem=7;bottomitem=7) //Which mean those variables must be 7 to activate, not one of them
Try
- Code: Select all
if(topitem=7, bodyitem=7, bottomitem=7)
No, it's not like that.
Werty (and everyone who uses ifs), for checking if a variable is equal to something you need two (2) ='s. When you use only one, you set the variable equal to the value you're trying to check if it is equal. So your code would result to topitem, bodyitem and bottomitem having the value of 7.
And for if statements && stands for AND and || stands for OR. These are foundable in the forum, there is several tutorials about operators
the ge's code uses. One of them is here:
viewtopic.php?f=27&t=12246The tutorial is very easy to understand. Please read it and you will understand all you need to know about ifs.
So your code would have to be:
- Code: Select all
if (topitem == 7 && bodyitem == 7 && bottomitem == 7)
{
//Here comes the code that triggers when the if statement is true -> all the variables are equal to 7.
}
I hope this helps.