AnimationTree

Inherits: Node < Object

Un nodo para ser usado para transiciones de animación avanzadas en un AnimationPlayer.

Descripción

A node to be used for advanced animation transitions in an AnimationPlayer.

Note: When linked with an AnimationPlayer, several properties and methods of the corresponding AnimationPlayer will not function as expected. Playback and transitions should be handled using only the AnimationTree and its constituent AnimationNode(s). The AnimationPlayer node should be used solely for adding, deleting, and editing animations.

Tutoriales

Propiedades

bool

active

false

NodePath

anim_player

NodePath("")

AnimationProcessMode

process_mode

1

NodePath

root_motion_track

NodePath("")

AnimationNode

tree_root

Métodos

void

advance ( float delta )

Transform

get_root_motion_transform ( ) const

void

rename_parameter ( String old_name, String new_name )

Enumeraciones

enum AnimationProcessMode:

  • ANIMATION_PROCESS_PHYSICS = 0 --- Las animaciones progresarán durante el fotograma de la física (es decir, Node._physics_process).

  • ANIMATION_PROCESS_IDLE = 1 --- Las animaciones progresarán durante el fotograma inactivo (es decir, Node._process).

  • ANIMATION_PROCESS_MANUAL = 2 --- Las animaciones sólo progresarán manualmente (ver advance).

Descripciones de Propiedades

Default

false

Setter

set_active(value)

Getter

is_active()

Si true, el AnimationTree se procesará.


Default

NodePath("")

Setter

set_animation_player(value)

Getter

get_animation_player()

La ruta al AnimationPlayer utilizada para la animacion.


Default

1

Setter

set_process_mode(value)

Getter

get_process_mode()

El modo de proceso de este AnimationTree. Ver AnimationProcessMode para los modos disponibles.


Default

NodePath("")

Setter

set_root_motion_track(value)

Getter

get_root_motion_track()

The path to the Animation track used for root motion. Paths must be valid scene-tree paths to a node, and must be specified starting from the parent node of the node that will reproduce the animation. To specify a track that controls properties or bones, append its name after the path, separated by ":". For example, "character/skeleton:ankle" or "character/mesh:transform/local".

If the track has type Animation.TYPE_TRANSFORM, the transformation will be cancelled visually, and the animation will appear to stay in place. See also get_root_motion_transform and RootMotionView.


Setter

set_tree_root(value)

Getter

get_tree_root()

El nodo de animación raíz de este AnimationTree. Ver AnimationNode.

Descripciones de Métodos

  • void advance ( float delta )

Avanza manualmente las animaciones en el tiempo especificado (en segundos).


  • Transform get_root_motion_transform ( ) const

Retrieve the motion of the root_motion_track as a Transform that can be used elsewhere. If root_motion_track is not a path to a track of type Animation.TYPE_TRANSFORM, returns an identity transformation. See also root_motion_track and RootMotionView.


  • void rename_parameter ( String old_name, String new_name )