SAnimatorStateInfo
Index
Functions Index
| Function Name |
|---|
| bool IsName (string name) |
| bool IsTag (string tag) |
Properties Index
| Property Name |
|---|
int fullPathHash get |
int nameHash get |
int shortNameHash get |
float normalizedTime get |
float length get |
float speed get |
float speedMultiplier get |
int tagHash get |
bool loop get |
float Length get |
Functions
IsName
bool IsName (string name)
Does name match the name of the active state in the statemachine?
| Parameter | Type | Description |
|---|---|---|
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
AnimationStateInfo.isName("aStateName")
IsTag
bool IsTag (string tag)
Does tag match the tag of the active state in the statemachine.
| Parameter | Type | Description |
|---|---|---|
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
AnimationStateInfo.isTag("aStateTag")
Properties
fullPathHash
int fullPathHash get
The full path hash for this state. The hash is generated using Animator.StringToHash.
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
fullPathHash = AnimationStateInfo.fullPathHash
nameHash
int nameHash get
The hashed name of the State.
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
nameHash= AnimationStateInfo.nameHash
shortNameHash
int shortNameHash get
The hash is generated using SAnimator.StringToHash. The hash does not include the name of the parent layer.
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
shortNameHash= AnimationStateInfo.shortNameHash
normalizedTime
float normalizedTime get
Normalized time of the State. The integer part is the number of time a state has been looped. The fractional part is the % (0-1) of progress in the current loop.
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
normalizedTime= AnimationStateInfo.normalizedTime
length
float length get
Current duration of the state. In seconds Can vary when the State contains a Blend Tree.
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
length= AnimationStateInfo.length
speed
float speed get
The playback speed of the animation. 1 is the normal playback speed. A negative playback speed will play the animation from the end.
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
speed= AnimationStateInfo.speed
speedMultiplier
float speedMultiplier get
_The speed multiplier for this state.
A negative speed multiplier will play the animation backwards. If no speed parameter as been set for this SAnimatorState, the default value will be 1._
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
speedMultiplier= AnimationStateInfo.speedMultiplier
tagHash
int tagHash get
_The Tag of the State.
The hash is generated using SAnimator.StringToHash._
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
tagHash= AnimationStateInfo.tagHash
loop
bool loop get
Is the state looping. All animations in the state must be looping.
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
loop= AnimationStateInfo.loop
Length
float Length get
Current duration of the state. In seconds Can vary when the State contains a Blend Tree
- Lua
AnimationStateInfo = Space.Host.ExecutingObject.Animator.GetCurrentAnimationStateInfo(0)
Length= AnimationStateInfo.Length