- Home /
Extra frames being added to animation
I'm using the new 2D version of Unity, and my animation was working fine. I was using basic frame-to-frame sprite animation for a walk cycle, with a child GameObject attached to the head which "bobbed" up and down.
I changed the pivot on my sprite, which meant I had to change the position of the child GameObject. However, when I did, Unity seems to have added an extra frame onto the end of my walk cycle -- there are no keyframes there, but Unity has decided to stay on the last keyframe for one frame longer than it should.
I don't understand why it would do that. It was working completely fine -- the only thing I changed as the position of an object, and I didn't add any extra frames or anything. There are a couple solutions out there, but they all date back to 2012 and don't work with newer versions of Unity. Any help?
Answer by belvita · Dec 01, 2013 at 08:54 AM
Please show some codes
I don't see how code would be relevant -- there's no code that modifies my animations. I'm using Unity's native animation dopesheet in the editor, and when I made an adjustment to the animation, an extra frame was added (I have not modified anything that would add the extra frame). There isn't any code to show, Unity just added an extra frame at the end.