AnimationNodeBlendTree
A sub-tree of many type AnimationNode
s used for complex animations. Used by AnimationTree
.
class AnimationNodeBlendTree
This animation node may contain a sub-tree of any other type animation nodes, such as AnimationNodeTransition
, AnimationNodeBlend2
, AnimationNodeBlend3
, AnimationNodeOneShot
, etc. This is one of the most commonly used animation node roots.
An AnimationNodeOutput
node named output
is created by default.
This object emits the following signals:
Superclasses
class AnimationRootNode
Base class for
AnimationNode
s that hold one or multiple composite animations. Usually used fortreeRoot
.
Citizens in SwiftGodot
Conformances
protocol CustomStringConvertible
A type with a customized textual representation.
protocol Equatable
A type that can be compared for value equality.
protocol Hashable
A type that can be hashed into a
Hasher
to produce an integer hash value.protocol Identifiable<ID>
A class of types whose instances hold the value of an entity with stable identity.
protocol VariantRepresentable
Types that conform to VariantRepresentable can be stored directly in
Variant
with no conversion. These include all of the Variant types from Godot (for exampleGString
,Rect
,Plane
), Godot objects (those that subclass SwiftGodot.Object) as well as the built-in Swift types UInt8, Int64 and Double.protocol VariantStorable
Types that conform to VariantStorable can be stored in a Variant and can be extracted back out of a Variant.
Types
class Signal1
Signal support.
Type members
static let connectionErrorConnectionExists: Int
The specified connection already exists.
static let connectionErrorNoInput: Int
The input node is
null
.static let connectionErrorNoInputIndex: Int
The specified input port is out of range.
static let connectionErrorNoOutput: Int
The output node is
null
.static let connectionErrorSameNode: Int
Input and output nodes are the same.
static let connectionOk: Int
The connection was successful.
class var godotClassName: StringName
Instance members
var graphOffset: Vector2
The global offset of all sub animation nodes.
var nodeChanged: Signal1
Emitted when the input port information is changed.
func addNode(name: StringName, node: AnimationNode?, position: Vector2
) Adds an
AnimationNode
at the givenposition
. Thename
is used to identify the created sub animation node later.func connectNode(inputNode: StringName, inputIndex: Int32, outputNode: StringName
) Connects the output of an
AnimationNode
as input for anotherAnimationNode
, at the input port specified byinputIndex
.func disconnectNode(inputNode: StringName, inputIndex: Int32
) Disconnects the animation node connected to the specified input.
func getNode(name: StringName
) -> AnimationNode? Returns the sub animation node with the specified
name
.func getNodePosition(name: StringName
) -> Vector2 Returns the position of the sub animation node with the specified
name
.func hasNode(name: StringName
) -> Bool Returns
true
if a sub animation node with specifiedname
exists.func removeNode(name: StringName
) Removes a sub animation node.
func renameNode(name: StringName, newName: StringName
) Changes the name of a sub animation node.
func setNodePosition(name: StringName, position: Vector2
) Modifies the position of a sub animation node.