Skip to main content

Condition

Conditions are used to check if a Property satisfies a particular criteria. They are mainly used as part of If statements or to specify prerequisites for a feat.

note

When used for a feat prerequisite Conditions are considered statements and must end in a ;.

Syntax

Conditions begin with the condition keyword followed by the left-hand side, then the comparison operator and finally the right-hand side.

Alternatively, the left-hand side, comparison operator and right-hand side can all be contained with the { and } symbols.

Left-Hand Side (LHS)

The left-hand side of a Condition can be either a Property or a Math expression.

Right-Hand Side (RHS)

The right-hand side of a Condition must be a Property or Value.

Comparison Operator

The comparison operator can be one of the following:

SymbolCheck
==LHS and RHS are equal
>=LHS is greater than or equal to RHS
<=LHS is less than or equal to RHS
>LHS is strictly greater than RHS
<LHS is strictly less than RHS
containsLHS contains RHS

Multiple Conditions

Multiple conditions can be combined using the and or or keywords followed by a list of conditions. Expressions beginning with and and or are themselves considered conditions so they be nested to reflect complex criteria.

Negation

Conditions can be negated by adding the not keyword at the beginning.

Examples

Character Level is at least 5

condition character.level >= 5

or

{character.level >= 5}

Perception is a class skill

{character.perception.classSkill == true}

Charisma is at least 15 and 5 ranks in Intimidate

and [condition character.charisma >= 15, condition character.intimidate.ranks >= 5]

Proficiency in basic melee weapons or small arms

or [{character.proficiency.weapon contains smallArm}, {character.proficiency.weapon contains basicMelee}]

Has "Limited Telepathy" racial trait

{character.racialTraitNames contains 'Limited Telepathy'}

Not wearing heavy armor

not {character.equipped.armorType == heavy}