I was wondering if anybody new any code for making an animation play for a set number of seconds (or frames) then stop? Also if you could make the animation start mid way through at a set point? Thank you in advance for any help
animation.Play(“walk”);
yield WaitForSeconds(2);
animation.Stop(“walk”);
That’s probably the easiest way, unless you needed something dynamic and robust.
to start mid way try something like:
animation[“walk”].time = animation[“walk”].length / 2.0f;