Exemple #1
0
 /// <summary>
 /// Starts the Spriter Animator using the spriter animator. Set the animator and layers later.
 /// DON'T forget to call Update() every frame to handle automatic transitions between states.
 /// </summary>
 /// <param name="animator">The animator to be handled.</param>
 /// <param name="layerAmount">The number of layers in this animator. (Default is 1. The layer number "0")</param>
 public SpriterAnimator(UnityAnimator animator, int layerAmount = 1)
 {
     spriterAnimator    = animator;
     spriterLayerAmount = layerAmount;
     useUnityAnim       = false;
     IsReady            = false;
 }
Exemple #2
0
 /// <summary>
 /// Setup the spriter animator. Set the animator and layers later.
 /// </summary>
 /// <param name="animator">The animator to be handled.</param>
 /// <param name="layerAmount">The number of layers in this animator. (Default is 1. The layer number "0")</param>
 public void SetupSpriterAnimator(UnityAnimator animator, int layerAmount = 1)
 {
     spriterAnimator    = animator;
     spriterLayerAmount = layerAmount;
 }