Else
else runs the line or block after it only when the if before it was false. When the
if was true, the script skips it.
Parameters
Section titled “Parameters”| Parameter | Meaning |
|---|---|
lines |
Optional. Without a block, how many of the following lines belong to the else. Default: 1. |
Where it goes
Section titled “Where it goes”Put else right after the line or block of its if. Blank lines in between are fine; any other line in
between breaks the pairing.
A block is a { line, the lines to run, and a matching } line. The { has to be the very next line:
a blank line or a comment in between means only that line belongs to the command, and the block after it
runs every time. Braces go on lines of their own.
Example
Section titled “Example”set %a #falseif %a display ok a is trueelse display ok a is false ; this one is shownhaltSee if for blocks, the line-count form and nesting.
See also
Based on the EasyUO wiki, edited for EasyUO Reforged. This text is available under the GNU Free Documentation License 1.2.