Skip to content

ASCueAnimation

PT | EN
Inherits: ASCue

Cue specialized for playing animations.

Description

[ASCueAnimation] is a specialized cue that automatically plays animations when triggered. It works with [AnimationPlayer], [AnimatedSprite2D], and [AnimatedSprite3D] nodes provided to the [ASComponent].

Create a .tres resource of this type, set the [member animation_name] property, and add it to your [ASAbility]’s [member ASAbility.cues] list. When the ability is activated, the animation will play on the target node.

Example:


# Create hit_animation.tres (ASCueAnimation)
# cue_tag: "hit_animation"
# animation_name: "hit"
# event_type: OnExecute

// Create hit_animation.tres (ASCueAnimation)
// cue_tag: "hit_animation"
// animation_name: "hit"
// event_type: OnExecute

Properties

TypeNameDefault
Stringanimation_name""
Name of the animation to play. The cue will look for a node with the alias [member ASCue.node_name] in the component’s registry. If no name is specified, the component will try its default animation nodes.