Counted number of animations to use.
Refactored animation.