Currently scrub will fire callbacks, but not all of them under all conditions.
For example:
- If the animation is not yet playing
- And scrub is called
- Then onAnimationStart will not be called on the first animation in the queue
Note that when this is fixed take care for callbacks not to happen multiple times. The following code could cause it to be triggered twice:
final anim = Anim();
anim.play("Walk"); // Triggers onStart
anim.scrub(0.7); // Since time hasn't progressed, might trigger on start again
onStart should probably be triggered in scrub, not in play or _playNext.