S2ENGINE HD 2020
User guide
×
Menu
Index

Animations

GameMachine Finite State Machines are also designed for managing animation transitions.
 
Every state node of an FSM can play an animation (see also Editing Animations), transition between states correspond to transition (blending) between animations.
When a state is associated to an animation, it plays the animation when it starts and when animation finishes it fires an ANIMATION_FINISHED event, so you can define a transition to another state that is processed when this event occurs:

Animations played in a state are, by default, always played in loop.

 
When you link a gms (GameMachine) resource to an object inside the scene, and this object owns a modelscript (see Editing Animations) FSM automatically has access to all animations defined for that object.
To associate an animation to a state use AnimTab.
 
When a GameMachine is associated to an object, in the GameMachine GraphViewport it is showed the name of the owner object in yellow color (see GameMachine owner).