PDA

View Full Version : && is used for "and", but what is "or"



beefster09
01-18-2007, 09:29 PM
In if-loops, what is used for "or" when you define the conditions? It's absolutely necessary for me to prevent the player from being able to get a double delay out of the Beamos's eye.

it can't be '//', that's for comments

Saffith
01-18-2007, 09:43 PM
It's ||

beefster09
01-19-2007, 11:28 PM
One more question, which is priority with conditions? "and" or "or"?

Here is an example. If you wanted something to happen when p condition is met and either q condition or r condition is too, would it be:
p && q || p && r
or
p && q || r

simplified question
in the conditions p && q || r, would it be interpreted as:
(p && q) || r
or
p && (q || r)