SelectAnimationByAction sets the current animation. An nil action value selects the default animation.
(action *Animation)
| 46 | // SelectAnimationByAction sets the current animation. |
| 47 | // An nil action value selects the default animation. |
| 48 | func (ac *AnimationComponent) SelectAnimationByAction(action *Animation) { |
| 49 | ac.CurrentAnimation = action |
| 50 | ac.index = 0 |
| 51 | } |
| 52 | |
| 53 | // AddDefaultAnimation adds an animation which is used when no other animation is playing. |
| 54 | func (ac *AnimationComponent) AddDefaultAnimation(action *Animation) { |
no outgoing calls