Sequine - Scripting API
|
Sequine Player is a component that can play Animation Clip on demand without relying on Animator Controller. More...
Classes | |
class | LayerRegistry |
Public Member Functions | |
bool | TryGetCurrentClip (out AnimationClip _clip) |
Try get the clip of the current state in base layer if not null. More... | |
void | RemoveState (AnimationClip _clip) |
Remove a state in base layer. More... | |
SequineState | PlayAnimationClip (AnimationClip _clip, AnimationConfig _config, bool _restart=false, Action _onComplete=null) |
SequineState | PlayAnimationClip (AnimationClip _clip, AnimationConfig _config, Action _onComplete) |
SequineState | PlayAnimationClip (int _layer, AnimationClip _clip, AnimationConfig _config, bool _restart=false, Action _onComplete=null) |
SequineState | PlayRangedAnimationClip (int _layer, AnimationClip _clip, AnimationConfig _config, float minTimePercentage, float _maxTimePercentage, bool _restart=false, Action _onComplete=null) |
Plays an animation clip, and only play within the percentaged range. More... | |
void | Stop () |
Stop all layers. More... | |
void | Pause () |
void | Resume () |
void | ExitCurrentState (int _layer) |
SequineState | PlayAction (int _id, AnimationConfig _config, bool _restart=false, Action _onComplete=null) |
SequineState | PlayAction (int _id, AnimationConfig _config, Action _onComplete) |
SequineState | PlayAction (int _layer, int _id, AnimationConfig _config, bool _restart=false, Action _onComplete=null) |
SequineState | PlayActionWithTranslation (int _id, Vector3 _translation, AnimationConfig _config, bool _restart=false, Action _onComplete=null, EasingFunction.Ease _easing=EasingFunction.Ease.Linear) |
SequineState | PlayActionWithTranslation (int _layer, int _id, Vector3 _translation, AnimationConfig _config, bool _restart=false, Action _onComplete=null, EasingFunction.Ease _easing=EasingFunction.Ease.Linear) |
bool | TryGetState (AnimationClip _clip, out SequineState _state) |
Try get state in base layer. More... | |
bool | TryGetActionClip (int _actionId, out AnimationClip _clip) |
void | Tick (float _deltaTime) |
void | PauseAnimationClipAtTime (AnimationClip _clip, float _time, bool _useNormalizedTime) |
Pauses an animation (if the clip is currently playing) by specifying the animation clip asset, and sample a certain pose at the specified time. This will also automatically plays the animation clip if it's not yet played. Since AnimationConfig parameter is not specified, the default animation config will be used as the configuration to play when it's not yet played. More... | |
void | PauseAnimationClipAtTime (AnimationClip _clip, float _time, bool _useNormalizedTime, AnimationConfig _config) |
Pauses an animation (if the clip is currently playing) by specifying the animation clip asset, and sample a certain pose at the specified time. This will also automatically plays the animation clip if it's not yet played. More... | |
Static Public Member Functions | |
static SequinePlayer | GetInstance (SequineAnimationData _binder) |
static bool | TryGetInstance (SequineAnimationData _binder, out SequinePlayer _sequinePlayer) |
Protected Member Functions | |
virtual void | OnValidate () |
virtual void | Awake () |
virtual void | OnEnable () |
virtual void | OnDisable () |
virtual void | OnDestroy () |
virtual void | OnActionTranslation (Vector3 _updatedPosition) |
Properties | |
static AnimationConfig | defaultAnimationConfig [get] |
SequineAnimationData | animationData [get] |
SequineState | currentState [get] |
IEnumerable< SequineState > | states [get] |
List< SequineLayer > | layers [get] |
Get runtime layers. This will be empty when accessed during edit mode. Use layerCount and layerNames in edit mode instead. More... | |
int | layerCount [get] |
string[] | layerNames [get] |
UpdateMode | updateMode [getset] |
float | weight [getset] |
Animator | animator [get] |
RuntimeAnimatorController | animatorController [getset] |
Sequine Player is a component that can play Animation Clip on demand without relying on Animator Controller.
|
protectedvirtual |
void Calcatz.Sequine.SequinePlayer.ExitCurrentState | ( | int | _layer | ) |
|
static |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
void Calcatz.Sequine.SequinePlayer.Pause | ( | ) |
void Calcatz.Sequine.SequinePlayer.PauseAnimationClipAtTime | ( | AnimationClip | _clip, |
float | _time, | ||
bool | _useNormalizedTime | ||
) |
Pauses an animation (if the clip is currently playing) by specifying the animation clip asset, and sample a certain pose at the specified time. This will also automatically plays the animation clip if it's not yet played. Since AnimationConfig parameter is not specified, the default animation config will be used as the configuration to play when it's not yet played.
_clip | |
_time | |
_useNormalizedTime |
void Calcatz.Sequine.SequinePlayer.PauseAnimationClipAtTime | ( | AnimationClip | _clip, |
float | _time, | ||
bool | _useNormalizedTime, | ||
AnimationConfig | _config | ||
) |
Pauses an animation (if the clip is currently playing) by specifying the animation clip asset, and sample a certain pose at the specified time. This will also automatically plays the animation clip if it's not yet played.
_clip | |
_time | |
_useNormalizedTime | |
_config |
SequineState Calcatz.Sequine.SequinePlayer.PlayAction | ( | int | _id, |
AnimationConfig | _config, | ||
Action | _onComplete | ||
) |
SequineState Calcatz.Sequine.SequinePlayer.PlayAction | ( | int | _id, |
AnimationConfig | _config, | ||
bool | _restart = false , |
||
Action | _onComplete = null |
||
) |
SequineState Calcatz.Sequine.SequinePlayer.PlayAction | ( | int | _layer, |
int | _id, | ||
AnimationConfig | _config, | ||
bool | _restart = false , |
||
Action | _onComplete = null |
||
) |
SequineState Calcatz.Sequine.SequinePlayer.PlayActionWithTranslation | ( | int | _id, |
Vector3 | _translation, | ||
AnimationConfig | _config, | ||
bool | _restart = false , |
||
Action | _onComplete = null , |
||
EasingFunction.Ease | _easing = EasingFunction.Ease.Linear |
||
) |
SequineState Calcatz.Sequine.SequinePlayer.PlayActionWithTranslation | ( | int | _layer, |
int | _id, | ||
Vector3 | _translation, | ||
AnimationConfig | _config, | ||
bool | _restart = false , |
||
Action | _onComplete = null , |
||
EasingFunction.Ease | _easing = EasingFunction.Ease.Linear |
||
) |
SequineState Calcatz.Sequine.SequinePlayer.PlayAnimationClip | ( | AnimationClip | _clip, |
AnimationConfig | _config, | ||
Action | _onComplete | ||
) |
SequineState Calcatz.Sequine.SequinePlayer.PlayAnimationClip | ( | AnimationClip | _clip, |
AnimationConfig | _config, | ||
bool | _restart = false , |
||
Action | _onComplete = null |
||
) |
SequineState Calcatz.Sequine.SequinePlayer.PlayAnimationClip | ( | int | _layer, |
AnimationClip | _clip, | ||
AnimationConfig | _config, | ||
bool | _restart = false , |
||
Action | _onComplete = null |
||
) |
SequineState Calcatz.Sequine.SequinePlayer.PlayRangedAnimationClip | ( | int | _layer, |
AnimationClip | _clip, | ||
AnimationConfig | _config, | ||
float | minTimePercentage, | ||
float | _maxTimePercentage, | ||
bool | _restart = false , |
||
Action | _onComplete = null |
||
) |
Plays an animation clip, and only play within the percentaged range.
Note that you can't get this state using TryGetState method as they're not bound to clip. One clip might have multiple SequineRangedStates to enable blending between the same clip at different time.
_layer | |
_clip | |
_config | |
minTimePercentage | |
_maxTimePercentage | |
_restart | |
_onComplete |
void Calcatz.Sequine.SequinePlayer.RemoveState | ( | AnimationClip | _clip | ) |
Remove a state in base layer.
_clip |
void Calcatz.Sequine.SequinePlayer.Resume | ( | ) |
void Calcatz.Sequine.SequinePlayer.Stop | ( | ) |
Stop all layers.
void Calcatz.Sequine.SequinePlayer.Tick | ( | float | _deltaTime | ) |
bool Calcatz.Sequine.SequinePlayer.TryGetActionClip | ( | int | _actionId, |
out AnimationClip | _clip | ||
) |
bool Calcatz.Sequine.SequinePlayer.TryGetCurrentClip | ( | out AnimationClip | _clip | ) |
Try get the clip of the current state in base layer if not null.
_clip |
|
static |
bool Calcatz.Sequine.SequinePlayer.TryGetState | ( | AnimationClip | _clip, |
out SequineState | _state | ||
) |
Try get state in base layer.
_clip | |
_state |
|
get |
|
get |
|
getset |
|
get |
|
staticget |
|
get |
|
get |
|
get |
Get runtime layers. This will be empty when accessed during edit mode. Use layerCount and layerNames in edit mode instead.
|
get |
|
getset |
|
getset |