Statement: Condition, Type: Initial
If
Format: If support-condition { support-condition... }
begin-identifier
end-identifier
where
-
support-condition = one or more of any valid series of supporting condition identifiers to complete a condition statement.
-
begin-identifier = the begin keyword identifier to denote the beginning of a condition block
-
end-identifier = the end keyword identifier to denote the end of a condition block.
Description
The If identifier reads the initial support-condition to build a condition statement. Depending on the initial support-condition one or more supporting condition identifiers may be required. Once all required support-conditions are read and validated by the compiler, a condition block is created that contains two logical outcomes: true or false.
When the outcome of the condition is evaluated as true the program control is passed to the body of the condition block. From there, the system will then execute all action and condition statements inside of the condition block between the begin-identifier and end-identifier. At this point, program control exists the condition block. If an Exit identifier is encountered inside the condition block, the program control will be passed back to the main view awaiting for another spin to be processed.
If the outcome of the condition is evaluated as false, the program control will completely skip the entire condition block and program control will be passed to the location just past the end-identifier of the condition block.
Condition Block
A condition block of a condition statement is identified with a begin-identifier and end-identifier that goes with the condition statement. Just after the complete condition statement, a begin-identifier is required to tell the compiler that this is the beginning of the condition block. For every begin-identifier there must be an end-identifier to denote the end of the condition block.
The condition statement, While has the same functionality as the If statement. Both are provided for User preference. |
Example 1
We want to determine if the roulette layout Black has not appeared in 4 times and if so, place a 5 unit bet on the roulette layout Black. The supporting condition identifiers, Black, not hit and integer (4) instructs the compiler to evaluate this condition statement as true only when the roulette layout Black has not appeared within the last 4 occurrences. The following example will perform this task.
RX Script | Copy Code |
---|---|
If Black has not hit in 4 times begin Put 5 units on Black end |
Example 2
We want to determine if the roulette layout 1st Dozen has lost more than 5 times while placing bets on this layout and if so, place a 50 unit bet on the roulette layout 1st Dozen. The supporting condition identifiers, 1st Dozen, lost more and integer (5) instructs the compiler to evaluate this condition statement as true only when the roulette layout 1st Dozen has lost more than 5 times. The following example will perform this task.
RX Script | Copy Code |
---|---|
If 1st Dozen has lost more than 5 times begin Put 50 units on 1st Dozen end |