AnimationNodeOneShot

package
v0.0.0-...-c909628 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 13, 2025 License: MIT Imports: 22 Imported by: 0

Documentation

Overview

Package AnimationNodeOneShot provides methods for working with AnimationNodeOneShot object instances.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Advanced

type Advanced = class

Advanced exposes a 1:1 low-level instance of the class, undocumented, for those who know what they are doing.

type Any

type Any interface {
	gd.IsClass
	AsAnimationNodeOneShot() Instance
}

type Instance

type Instance [1]gdclass.AnimationNodeOneShot

A resource to add to an [AnimationNodeBlendTree]. This animation node will execute a sub-animation and return once it finishes. Blend times for fading in and out can be customized, as well as filters. After setting the request and changing the animation playback, the one-shot node automatically clears the request on the next process frame by setting its [code]request[/code] value to [constant ONE_SHOT_REQUEST_NONE]. [codeblocks] [gdscript] # Play child animation connected to "shot" port. animation_tree.set("parameters/OneShot/request", AnimationNodeOneShot.ONE_SHOT_REQUEST_FIRE) # Alternative syntax (same result as above). animation_tree["parameters/OneShot/request"] = AnimationNodeOneShot.ONE_SHOT_REQUEST_FIRE

# Abort child animation connected to "shot" port. animation_tree.set("parameters/OneShot/request", AnimationNodeOneShot.ONE_SHOT_REQUEST_ABORT) # Alternative syntax (same result as above). animation_tree["parameters/OneShot/request"] = AnimationNodeOneShot.ONE_SHOT_REQUEST_ABORT

# Abort child animation with fading out connected to "shot" port. animation_tree.set("parameters/OneShot/request", AnimationNodeOneShot.ONE_SHOT_REQUEST_FADE_OUT) # Alternative syntax (same result as above). animation_tree["parameters/OneShot/request"] = AnimationNodeOneShot.ONE_SHOT_REQUEST_FADE_OUT

# Get current state (read-only). animation_tree.get("parameters/OneShot/active") # Alternative syntax (same result as above). animation_tree["parameters/OneShot/active"]

# Get current internal state (read-only). animation_tree.get("parameters/OneShot/internal_active") # Alternative syntax (same result as above). animation_tree["parameters/OneShot/internal_active"] [/gdscript] [csharp] // Play child animation connected to "shot" port. animationTree.Set("parameters/OneShot/request", (int)AnimationNodeOneShot.OneShotRequest.Fire);

// Abort child animation connected to "shot" port. animationTree.Set("parameters/OneShot/request", (int)AnimationNodeOneShot.OneShotRequest.Abort);

// Abort child animation with fading out connected to "shot" port. animationTree.Set("parameters/OneShot/request", (int)AnimationNodeOneShot.OneShotRequest.FadeOut);

// Get current state (read-only). animationTree.Get("parameters/OneShot/active");

// Get current internal state (read-only). animationTree.Get("parameters/OneShot/internal_active"); [/csharp] [/codeblocks]

var Nil Instance

Nil is a nil/null instance of the class. Equivalent to the zero value.

func New

func New() Instance

func (Instance) AsAnimationNode

func (self Instance) AsAnimationNode() AnimationNode.Instance

func (Instance) AsAnimationNodeOneShot

func (self Instance) AsAnimationNodeOneShot() Instance

func (Instance) AsAnimationNodeSync

func (self Instance) AsAnimationNodeSync() AnimationNodeSync.Instance

func (Instance) AsObject

func (self Instance) AsObject() [1]gd.Object

func (Instance) AsRefCounted

func (self Instance) AsRefCounted() [1]gd.RefCounted

func (Instance) AsResource

func (self Instance) AsResource() Resource.Instance

func (Instance) Autorestart

func (self Instance) Autorestart() bool

func (Instance) AutorestartDelay

func (self Instance) AutorestartDelay() Float.X

func (Instance) AutorestartRandomDelay

func (self Instance) AutorestartRandomDelay() Float.X

func (Instance) BreakLoopAtEnd

func (self Instance) BreakLoopAtEnd() bool

func (Instance) FadeinCurve

func (self Instance) FadeinCurve() [1]gdclass.Curve

func (Instance) FadeinTime

func (self Instance) FadeinTime() Float.X

func (Instance) FadeoutCurve

func (self Instance) FadeoutCurve() [1]gdclass.Curve

func (Instance) FadeoutTime

func (self Instance) FadeoutTime() Float.X

func (Instance) MixMode

func (Instance) SetAutorestart

func (self Instance) SetAutorestart(value bool)

func (Instance) SetAutorestartDelay

func (self Instance) SetAutorestartDelay(value Float.X)

func (Instance) SetAutorestartRandomDelay

func (self Instance) SetAutorestartRandomDelay(value Float.X)

func (Instance) SetBreakLoopAtEnd

func (self Instance) SetBreakLoopAtEnd(value bool)

func (Instance) SetFadeinCurve

func (self Instance) SetFadeinCurve(value [1]gdclass.Curve)

func (Instance) SetFadeinTime

func (self Instance) SetFadeinTime(value Float.X)

func (Instance) SetFadeoutCurve

func (self Instance) SetFadeoutCurve(value [1]gdclass.Curve)

func (Instance) SetFadeoutTime

func (self Instance) SetFadeoutTime(value Float.X)

func (Instance) SetMixMode

func (self Instance) SetMixMode(value gdclass.AnimationNodeOneShotMixMode)

func (*Instance) UnsafePointer

func (self *Instance) UnsafePointer() unsafe.Pointer

func (Instance) Virtual

func (self Instance) Virtual(name string) reflect.Value

type MixMode

type MixMode = gdclass.AnimationNodeOneShotMixMode //gd:AnimationNodeOneShot.MixMode
const (
	/*Blends two animations. See also [AnimationNodeBlend2].*/
	MixModeBlend MixMode = 0
	/*Blends two animations additively. See also [AnimationNodeAdd2].*/
	MixModeAdd MixMode = 1
)

type OneShotRequest

type OneShotRequest = gdclass.AnimationNodeOneShotOneShotRequest //gd:AnimationNodeOneShot.OneShotRequest
const (
	/*The default state of the request. Nothing is done.*/
	OneShotRequestNone OneShotRequest = 0
	/*The request to play the animation connected to "shot" port.*/
	OneShotRequestFire OneShotRequest = 1
	/*The request to stop the animation connected to "shot" port.*/
	OneShotRequestAbort OneShotRequest = 2
	/*The request to fade out the animation connected to "shot" port.*/
	OneShotRequestFadeOut OneShotRequest = 3
)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL