AnimationNode

Inherits: Resource < Reference < Object Inherited By: AnimationNodeAdd2, AnimationNodeAdd3, AnimationNodeBlend2, AnimationNodeBlend3, AnimationNodeOneShot, AnimationNodeOutput, AnimationNodeTimeScale, AnimationNodeTimeSeek, AnimationNodeTransition, AnimationRootNode AnimationTree nodes.

Description

AnimationTree nodes. In general, it’s not used directly, but you can create custom ones with custom blending formulas. AnimationNodeBlendTree, otherwise AnimationRootNode should be used instead.

Tutorials

  • Using AnimationTree

    Properties

    Methods

    Signals

  • removed_from_graph ( ) Emitted when the node was removed from the graph.

  • tree_changed ( ) AnimationNodeBlendSpace1D, AnimationNodeBlendSpace2D, AnimationNodeStateMachine, and AnimationNodeBlendTree.

    Enumerations

    FilterAction:
  • FILTER_IGNORE = 0 —- Do not use filtering.
  • FILTER_PASS = 1 —- Paths matching the filter will be allowed to pass.
  • FILTER_STOP = 2 —- Paths matching the filter will be discarded.
  • FILTER_BLEND = 3 —- Paths matching the filter will be blended (by the blend value).

    Property Descriptions

  • bool filter_enabled true, filtering is enabled.

    Method Descriptions

  • add_input ( String name ) AnimationNodeBlendTree.

  • blend_animation ( String animation, float time, float delta, bool seeked, float blend ) blend amount (name must be valid in the linked AnimationPlayer). A time and delta may be passed, as well as whether seek happened.

  • float blend_input ( int input_index, float time, bool seek, float blend, FilterAction filter=0, bool optimize=true ) AnimationNodeBlendTree. The time parameter is a relative delta, unless seek is true, in which case it is absolute. A filter mode may be optionally passed (see FilterAction for options).

  • float blend_node ( String name, AnimationNode node, float time, bool seek, float blend, FilterAction filter=0, bool optimize=true ) AnimationRootNode instead, else editors will not display your node for addition.

  • String get_caption ( ) virtual Gets the text caption for this node (used by some editors).

  • Object get_child_by_name ( String name ) virtual AnimationRootNode).

  • Dictionary get_child_nodes ( ) virtual name: node dictionary. Only useful when inheriting AnimationRootNode.

  • int get_input_count ( ) const AnimationNodeBlendTree.

  • String get_input_name ( int input ) Gets the name of an input by index.

  • Variant get_parameter ( String name ) const Gets the value of a parameter. Parameters are custom local memory used for your nodes, given a resource can be reused in multiple trees.

  • Variant get_parameter_default_value ( String name ) virtual Gets the default value of a parameter. Parameters are custom local memory used for your nodes, given a resource can be reused in multiple trees.

  • Array get_parameter_list ( ) virtual Object.get_property_list.

  • String has_filter ( ) virtual true whether you want the blend tree editor to display filter editing on this node.

  • bool is_path_filtered ( NodePath path ) const Returns whether the given path is filtered.

  • process ( float time, bool seek ) virtual time parameter is a relative delta, unless seek is true, in which case it is absolute. blend_input, blend_node or blend_animation functions. You can also use get_parameter and set_parameter to modify local memory. This function should return the time left for the current animation to finish (if unsure, pass the value from the main blend being called).

  • remove_input ( int index ) Removes an input, call this only when inactive.

  • set_filter_path ( NodePath path, bool enable ) Adds or removes a path for the filter.

  • set_parameter ( String name, Variant value ) Sets a custom parameter. These are used as local memory, because resources can be reused across the tree or scenes.