In terms of code, now there's no longer a representation of the Context. Instead, when the ritual's XML is parsed, the social context is loaded as pre-conditions.
The social context remains the same. For Time Conditions:
<Time value="morning" /> <!-- This means that all characters must be "in the morning" -->
<Time target="[character]" operator="=" value="morning" /> <!-- [character] must be "in the morning" -->
<Time target="[char-a]" operator="=" value="[char-b]" /> <!-- [char-a] must be in the same time as [char-b] -->
For Place Conditions:
<Place value="farm" /> <!-- This means that all characters must be at the farm -->
<Place target="[character]" operator="=" value="farm" /> <!-- [character] needs to be at the farm -->
<Place target="[char-a]" operator="=" value="[char-b]" /> <!-- [char-a] must be at the same place as [char-b] -->
Both Time and Place Conditions also support the keyword "any" on the value argument, which is as if the condition didn't exist (i.e. if the character is at any place or any time).
<Time value="any" /> <!-- The characters can be on any time -->
<Place value="any" /> <!-- The characters can be at any place -->
For Social Conditions:
<Social name="power" target="[char-a]" operator="=" value="[char-b]" /> <!-- [char-a] has the same power as [char-b] -->
<Social name="power" target="[char-a]" operator="<=" value="5" /> <!-- [character] has a power of 5 or lower -->
<Social name="host" target="[character]" operator="=" value="True" /> <!-- [character] is a host -->
No comments:
Post a Comment