User Tools

Site Tools


conditional_expression

Conditional Expression


A conditional expression is an expression that evaluates to either true or false. An operator at the middle of the expression (for example “==” to check equality) is used to compare two different values on each side of the operator (i.e. the left operand and right operand). Refer to the table below for a list of all operators currently supported.

OperatorExpression evaluates to true when:
==Left operand is equal to the right operand.
!=Left operand is not equal to the right operand.
<Left operand is less than the right operand.
< =Left operand is less than or equal to the right operand.
>Left operand is greater than the right operand.
> =Left operand is greater than or equal to the right operand.
containsLeft operand contains one or more of the right operand.

Examples:

self.property["visited"] == true
global.property["gems_collected"] >= 5
player.inventory contains "Gold Key"
conditional_expression.txt · Last modified: 2017/08/06 12:45 by justin