Behavior > Triggers


Read our article on Custom Events for an explanation of these blocks.


For Actor

Trigger Event in Specific Behavior (for Actor)

say-trigger-block

Triggers the custom event for a specific behavior that is attached to the specified actor.

[ACTOR].say([TEXT], "_customEvent_" + [TEXT]);

Trigger Event in All Behaviors (for Actor)

shout-trigger-block

Triggers the custom event for all behaviors that are attached to the specified actor.

[ACTOR].shout("_customEvent_" + [TEXT]);

For Scene

Trigger Event in Specific Behavior (for Scene)

say-trigger-block

Triggers the custom event for the specified behavior that is attached to the current scene.

sayToScene([TEXT], "_customEvent_" + [TEXT]);

Trigger Event in All Behaviors (for Scene)

shout-trigger-block

Triggers the custom event for all behaviors that are attached to the current scene.

shoutToScene("_customEvent_" + [TEXT]);

In this Behavior

Trigger Event (this Behavior)

global-trigger-block

Triggers a custom event in this behavior. This is a direct function call, so an event with the specified name must exist, otherwise it will cause a compilation error.

_customEvent_text();