- Home /
2D: initial sprite idle animation playing too fast upon game initiation until I input movement keys?
Hello everyone,
So odd problem I'm running into: I'm making a top down 2D adventure game and when I initialize my game, the default character facing is an animation that faces down, then after a wait of 4 or so seconds, a little glimmer passes over his helmet visor. I have all of the idle animations in a blend tree, although this down facing animation is the only one within the "Idle" blend tree that has more than one frame to it. The weird thing is is that when I first start the game, this down-facing idle animation plays WAY too fast and the helmet speed glimmers like every second, but then as soon as I move so that the animator switches from the idle blend tree to moving, then back to idle, the animation plays at the correct speed with the correct sample size I set in the animation (12 in this case). I can't figure out why the initial animation looks like it's playing with a sample size of 60 when the game initially starts until I move and it updates itself.
Hopefully that makes sense. I've double checked all the sample sizes for all the animations as well as the animation speed for the animation itself and everything looks correct for how fast the animation should be playing. In the animator controller for the player, I currently have the idle blend tree set as the default state. I tried putting in the down-idle animation separately as it's own state in the animator controller and having that be the default state instead, but that didn't work either. Is there a setting somewhere I'm missing that's causing this animation speed increase upon initiation? Has anyone run into something similar to this before?
Answer by BrendaSchmidt · Jun 21, 2018 at 06:00 PM
I'm having the same problem. Did you find a solution?
I finally just added a state at the beginning for my starting animation that is not part of the blend tree and when the player moved then it moves into the blend tree and now it is working. I'm not sure if this is a good way to do it or not.
I think I finally got the answer to this problem. On the blend tree of the initial animation you have to fill in an animation at the 0,0 point. If you do that, problem solved.
Oh man, thanks a lot. I've been taking apart my entire project for hours to find the problem. Thank you.
Your answer
Follow this Question
Related Questions
Blending animations for a bow with differing charges 1 Answer
Animation frozen 1 Answer
Can't set animator bool to True 1 Answer
blend tree animation through script? 0 Answers