wiki.sine.space | sinespace

Scripting/SAnimator

From wiki.sine.space
Revision as of 21:01, 17 December 2020 by Voidtech (Talk | contribs) (Added and defined all members (51) of SAnimator)

Jump to: navigation, search

==Members== 47

CrossFade

void CrossFade (string stateName, float transitionDuration);

Creates a dynamic transition between the current state and the destination state. stateName: The name of the destination state. transitionDuration: The duration of the transition. Value is in source state normalized time.


CrossFade

void CrossFade (string stateName, float transitionDuration, int layer);

Creates a dynamic transition between the current state and the destination state. stateName: The name of the destination state. transitionDuration: The duration of the transition. Value is in source state normalized time. layer: Layer index containing the destination state. If no layer is specified or layer is -1, the first state that is found with the given name or hash will be played.


CrossFade

void CrossFade (string stateName, float transitionDuration, int layer, float normalizedTime);

Creates a dynamic transition between the current state and the destination state. stateName: The name of the destination state. transitionDuration: The duration of the transition. Value is in source state normalized time. layer: Layer index containing the destination state. If no layer is specified or layer is -1, the first state that is found with the given name or hash will be played. normalizedTime: Start time of the current destination state. Value is in source state normalized time, should be between 0 and 1. If no explicit normalizedTime is specified or normalizedTime value is float.NegativeInfinity, the state will either be played from the start if it's not already playing, or will continue playing from its current time and no transition will happen.



CrossFadeInFixedTime

void CrossFadeInFixedTime (string stateName, float transitionDuration);

Creates a dynamic transition between the current state and the destination state. The duration and offset in the target state are in fixed time. stateName: The name of the destination state. transitionDuration: The duration of the transition. Value is in seconds.


CrossFadeInFixedTime

void CrossFadeInFixedTime (string stateName, float transitionDuration, int layer);

Creates a dynamic transition between the current state and the destination state. The duration and offset in the target state are in fixed time. stateName: The name of the destination state. transitionDuration: The duration of the transition. Value is in seconds. layer: Layer index containing the destination state. If no layer is specified or layer is -1, the first state that is found with the given name or hash will be played.


CrossFadeInFixedTime

void CrossFadeInFixedTime (string stateName, float transitionDuration, int layer, float fixedTime);

Creates a dynamic transition between the current state and the destination state. The duration and offset in the target state are in fixed time. stateName: The name of the destination state. transitionDuration: The duration of the transition. Value is in seconds. layer: Layer index containing the destination state. If no layer is specified or layer is -1, the first state that is found with the given name or hash will be played. fixedTime: Start time of the current destination state. Value is in seconds. If no explicit fixedTime is specified or fixedTime value is float.NegativeInfinity, the state will either be played from the start if it's not already playing, or will continue playing from its current time and no transition will happen.



GetBool

bool GetBool (string name);

Returns the value of the given boolean parameter. name: The name of the parameter.


GetBool

bool GetBool (int id);

Returns the value of the given boolean parameter. id: The id of the parameter.

<pre</pre>


GetFloat

float GetFloat (string name);

Returns the value of the given float parameter. name: The name of the parameter.


GetFloat

float GetFloat (int id);

Returns the value of the given float parameter. id: The id of the parameter.

<pre</pre>


GetInteger

int GetInteger (string name);

Returns the value of the given integer parameter. name: The name of the parameter.


GetInteger

int GetInteger (int id);

Returns the value of the given integer parameter. id: The id of the parameter.

<pre</pre>


GetLayerIndex

int GetLayerIndex (string layerName);

Gets the index of the layer with specified name.


GetLayerName

string GetLayerName (int layerIndex);

Gets name of the layer.


GetLayerWeight

float GetLayerWeight (int layerIndex);

Gets the layer's current weight.


GetLength

double GetLength Player will 'Delete' this item.

No documentation


GetLoop

bool GetLoop Player will 'Delete' this item.

No documentation


GetNormalizedTime

double GetNormalizedTime Player will 'Delete' this item.

No documentation


GetTime

double GetTime ();

Player will 'Delete' this item.


IsInTransition

bool IsInTransition Is the specified layer in a transition.

No documentation


IsParameterControlledByCurve

bool IsParameterControlledByCurve (int id);

Returns true if a parameter is controlled by an additional curve on an animation.


IsParameterControlledByCurve

bool IsParameterControlledByCurve (string name);

Returns true if a parameter is controlled by an additional curve on an animation.


Play

void Play (string stateName);

Plays a state. stateName: The name of the state to play.


Play

void Play (string stateName, int layer);

Plays a state. stateName: The name of the state to play. Layer index containing the destination state. If no layer is specified or layer is -1, the first state that is found with the given name or hash will be played.


Play

void Play (string stateName, int layer, float normalizedTime);

Plays a state. stateName: The name of the state to play. Layer index containing the destination state. If no layer is specified or layer is -1, the first state that is found with the given name or hash will be played. normalizedTime: Start time of the current destination state. Value is in normalized time. If no explicit normalizedTime is specified or value is float.NegativeInfinity, the state will either be played from the start if it's not already playing, or will continue playing from its current time.


PlayInFixedTime

void PlayInFixedTime (string stateName);

Plays a state. The offset in the target state is in fixed time. stateName: The name of the state to play.


PlayInFixedTime

void PlayInFixedTime (string stateName, int layer);

Plays a state. The offset in the target state is in fixed time. stateName: The name of the state to play. Layer index containing the destination state. If no layer is specified or layer is -1, the first state that is found with the given name or hash will be played.


PlayInFixedTime

void PlayInFixedTime (string stateName, int layer, float fixedTime);

Plays a state. The offset in the target state is in fixed time. stateName: The name of the state to play. Layer index containing the destination state. If no layer is specified or layer is -1, the first state that is found with the given name or hash will be played. fixedTime: Start time of the current destination state. Value is in seconds. If no explicit fixedTime is specified or fixedTime value is float.NegativeInfinity, the state will either be played from the start if it's not already playing, or will continue playing from its current time.


Rebind

void Rebind ();

Rebind all the animated properties and mesh data with the Animator.


ResetTrigger

void ResetTrigger (int id);

Resets the trigger parameter to false.


ResetTrigger

void ResetTrigger (string name);

Resets the trigger parameter to false.


SetBool

void SetBool (int id, bool value);

Sets the value of a boolean parameter.


SetBool

void SetBool (string name, bool value);

Sets the value of a boolean parameter.


SetFloat

void SetFloat (int id, float value);

Send float values to the Animator to affect transitions.


SetFloat

void SetFloat (int id, float value, float dampTime, float deltaTime);

Send float values to the Animator to affect transitions. dampTime: The damper total time. deltaTime: The delta time to give to the damper.


SetFloat

void SetFloat (string name, float value);

Send float values to the Animator to affect transitions.


SetFloat

void SetFloat (string name, float value, float dampTime, float deltaTime);

Send float values to the Animator to affect transitions. dampTime: The damper total time. deltaTime: The delta time to give to the damper.


SetInteger

void SetInteger (int id, int value);

Sets the value of the given integer parameter.


SetInteger

void SetInteger (string name, int value);

Sets the value of the given integer parameter.


SetLayerWeight

void SetLayerWeight (int layerIndex, float weight);

Sets the weight of the layer at the given index.


SetTime

void SetTime (double time);

Player will 'Delete' this item.


SetTrigger

void SetTrigger (int id);

Sets the value of the given trigger parameter.


SetTrigger

void SetTrigger (string trigger);

Sets the value of the given trigger parameter.


StartPlayback

void StartPlayback ();

Sets the animator in playback mode.


Stop

void Stop ();

Stop the Animator.


StopPlayback

void StopPlayback ();

Stops the animator playback mode. When playback stops, the avatar resumes getting control from game logic.


Update

void Update (float deltaTime);

Evaluates the animator based on deltaTime.




Properties

ApplyRootMotion

bool ApplyRootMotion { get; }

Should root motion be applied? Root motion is the effect where an object's entire mesh moves away from its starting point but that motion is created by the animation itself rather than by changing the Transform position.


Controller

SResource Controller { get;set; }

The Animator Controller resource of this Animator


Enabled

bool Enabled { get;set; }

Whether this is visually visible or not.


Parameters

[[Scripting/string[]|string[]]] Parameters { get;set; }

The AnimatorControllerParameter list used by the animator.