If-Else-Endif construction

If-else-endif construction used to act by conditions without using new functions or spamming triggers.

To start IF section use the next receiver/instruction:
!!if&condition:;
Note that 'if' is in lower case.
Condition is a standard AND and OR condition that you use now in any receiver. If during a script execution the condition evaluation is TRUE, the followed section is executed. If it is FALSE, the followed section is skipped until ELSE section begins or ENDIF found.

To start ELSE section use the next receiver/instruction:
!!el:;
'el' is in lower case.
No condition is evaluated even if present so this is unconditionally executed.
ELSE section always expects IF part and linked to the latest found in the script IF.

To end IF or IF-ELSE section use the next receiver/instruction:
!!en:;
'en' is in lower case.
No condition is evaluated even if present so this is unconditionally executed.
ENDIF section always expects IF part or IF_ELSE part and linked to the latest found in the script IF or IF-ELSE.

You may use included IF-ELSE-ENDIF sections but not deeper than 10 levels.
Although, according to ChangeLog2.txt, number of levels is now unlimited. Should be checked.

Every trigger (and thus function) has its own set of IF-ELSE-ENDIF and so may have up to 10 levels of included IF-ELSE-ENDIF.
When you call a function the caller IF-ELSE-ENDIF state stays active, so when you are back the local IF-ELSE-ENDIF set is used again (a similar way as local function variables).

Example:
ZVSE

!?HM-1;
!!VRv10:S5;
!!if&v10=5:;
    !!IF:M^First IF^;
    !!VRv10:S10;
    !!if&v10<>10:;
        !!IF:M^Second IF^;
    !!el:;
        !!IF:M^Second ELSE^;
    !!en:;
    !!IF:M^Second IF finished^;
!!el:;
    !!IF:M^First ELSE^;
    !!VRv10:S99;
    !!if&v10=99:;
        !!IF:M^Third IF^;
    !!el:;
        !!IF:M^Third ELSE^;
    !!en:;
    !!IF:M^Third IF finished^;
!!en:;
!!IF:M^First IF finished^;

You should see the next messages:
  First IF
  Second ELSE
  Second IF finished
  First IF finished