Tag

From Castle Wiki
Revision as of 21:05, 11 May 2022 by Ben (talk | contribs) (Created page with "'''Tags''' are a way of referring to Actors while playing a deck. Tags consist of a word, such as '''#wall''' or '''#player''', which can then be referenced inside [...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Tags are a way of referring to Actors while playing a deck. Tags consist of a word, such as #wall or #player, which can then be referenced inside Rules.

Adding and removing tags

When editing a deck, you can add tags to a Blueprint by opening the Inspector and navigating to the General tab. Blueprints can have many tags. All actors created from this blueprint will begin with this set of tags.

While a deck is playing, you can use the Add tag and Remove tag Responses to change tags on specific actors.

Common uses for tags

Colliding with certain actors

The Trigger for When this collides with an actor has an optional tag parameter. For example, if you want to do something when the player hits a wall (but not any other time), you could change the trigger to When this collides with tag #wall. Now the trigger will only fire when the player hits actors tagged #wall.

Telling certain actors to do something

The Tell actors with tag Response causes only those actors to perform whatever logic you want. For example, to destroy all oxen in the card, you can say: Tell all actors with tag #ox: Destroy this actor.

Moving toward another actor

The Move toward another actor Response can be filtered by tag. For example, to make the enemies chase the player, you could say: Move toward the closest actor with tag #player.