Lightstalker
New Member
- Reaction score
- 55
How can I use "and - all conditions are true" and "Or - any conditions are true" in vJASS?
return this and that and the_other_thing
return this or that or the_other_thing
JASS:return this and that and the_other_thing
JASS:return this or that or the_other_thing
if x == value and y == value then
//Code here
endif
// Integer/real only:
> // Greater than
< // Less than
>= // Greater than, or equal to
<= // Less than, or equal to
// All:
== // Equal to
!= // Not equal to
if (A) or (B) then
// blah
elseif (C) and (D) then
// blah
else
// blah
endif
// Example:
if someInt > 5 or someReal == bj_PI then
call KillUnit(u)
elseif someString == "Hello" and not SomeBoolean == not (true == false) then
call SetUnitX(u, 0)
endif