Difference between revisions of "Category:Conditions"

437 bytes added ,  09:12, 2 April 2012
changed link from Console Commands to Condition Functions, added another example to Comparison section
imported>Scornett-Bot
m (Script running global find and replace: = for '''=)
 
imported>Fg109
(changed link from Console Commands to Condition Functions, added another example to Comparison section)
Line 21: Line 21:




The Condition Function dropdown list is the function to run. See [[:Category:Console Commands|Console Commands]] for the complete list of script functions that can be used as conditions.
The Condition Function dropdown list is the function to run. See [[:Category:Condition Functions|Condition Functions]] for the complete list of script functions that can be used as conditions.


===Run On===
===Run On===
Line 48: Line 48:
The OR checkbox is used to determine how a Condition Item is evaluated with the ones that follow it. Consecutive ORs are treated like a single block when evaluating and have order preference over AND. For example, the condition items ( A AND B OR C AND D ) are evaluated as ( A AND ( B OR C ) AND D ) and not ( ( A AND B ) OR ( C AND D ) ).
The OR checkbox is used to determine how a Condition Item is evaluated with the ones that follow it. Consecutive ORs are treated like a single block when evaluating and have order preference over AND. For example, the condition items ( A AND B OR C AND D ) are evaluated as ( A AND ( B OR C ) AND D ) and not ( ( A AND B ) OR ( C AND D ) ).


By applying the distributive and other properties complex expressions can be converted into a list of Condition Items that will evaluate as intended. For example, the expression ((A AND B) OR (C AND D)) can be represented as the list of Condition Items (A OR C AND B OR C AND A OR D AND B OR D). As described above, this evaluates as ((A OR C) AND (B OR C) AND (A OR D) AND (B OR D)) which is equivalent to the initial expression.


[[Category:Quests]]
[[Category:Quests]]
Anonymous user