XML animations are defined at build time, but what if you want to make an animation that is defined or modified at runtime?
We want to be able to change the animation by changing the animation sequence that is playing at any particular time.
As you have learned from the Have A Go Hero—improve your dancing section, you can affect all manner of changes to the character of an animation, just by moving a few frames around. You can use Java in your application to add dynamic changes to the animation, by directly manipulating the
AnimationDrawable that defines the frame animation.