wiki.sine.space | sinespace

Scripting/SAnimationState

From wiki.sine.space
Revision as of 06:17, 22 December 2020 by Edisonwu (Talk | contribs) (Created page with "The AnimationState gives full control over animation blending. The interface allows users to modify speed, weight and time while any animation is playing. =Properties= {{Scr...")

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

The AnimationState gives full control over animation blending. The interface allows users to modify speed, weight and time while any animation is playing.


Properties

Enabled

bool Enabled [get, set]

Returns true if current AnimationState is enabled.

local anim=Space.Host.ExecutingObject.Animation

local state = anim.GetState()

Space.Log(state.Enabled)


Length

float Length [get;]

Returns the length of current animation.

local anim=Space.Host.ExecutingObject.Animation

local state = anim.GetState()

Space.Log(state.Length)


Name

string Name [get;]

Returns the name of current animation.

local anim=Space.Host.ExecutingObject.Animation

local state = anim.GetState()

Space.Log(state.Name)


NormalizedSpeed

float NormalizedSpeed [get, set]

Returns the normalized speed of current animation.

local anim=Space.Host.ExecutingObject.Animation

local state = anim.GetState()

Space.Log(state.NormalizedSpeed)


NormalizedTime

float NormalizedTime [get, set]

Returns the normalized time of current animation.

local anim=Space.Host.ExecutingObject.Animation

local state = anim.GetState()

Space.Log(state.NormalizedTime)


Speed

float Speed [get, set]

Returns the Speed of current animation.

local anim=Space.Host.ExecutingObject.Animation

local state = anim.GetState()

Space.Log(state.Speed)



Time

float Time [get, set]

Returns the Time of current animation.

local anim=Space.Host.ExecutingObject.Animation

local state = anim.GetState()

Space.Log(state.Time)


Weight

float Weight [get, set]

Returns the Weight of current animation.

local anim=Space.Host.ExecutingObject.Animation

local state = anim.GetState()

Space.Log(state.Weight)