From Castle Wiki
Revision as of 16:08, 13 May 2022 by Ben (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

A Condition is a type of Response which only runs its enclosed logic when a certain condition is true.

For example, imagine an adventure game where the player needs to use a pick to mine gold. When the player touches a piece of gold, you need to check if they have the pick to decide what to do. You might write a rule like this:

When this collides with tag #gold:
  If variable $has_axe equals 1:
    Tell the colliding actor: Destroy this actor
    Set variable $num_gold to 1 (Relative)
    Create text box "You need the axe to get the gold"

For more information on how to add conditions and responses, see Rules.

List of conditions



  • If this is colliding


  • If a coin flip shows heads


  • If this is in the camera viewport


  • If the animation frame meets a condition