The sad story of a model whose multiple animations worked, and another whose didn't

Model A = Horrible Monster

Model B = Victim

Both were made in Blender, animated, and exported in FBX format. They have a “walk” and a “melee” animation, separated by frame numbers, and animation compression is turned off. The animation is set up the same for each. The frame numbers themselves are different, but that is the only difference.

Model B decided to try out all her animations in Unity. Whichever animation was inputted into Unity first (ie. at the top of the list) worked, no matter which frames it covered. Ergo, Blender exported all keyframes correctly.

Then, Model B decided to put “walk” at the top of the list, and use a script that said animation.CrossFade(“melee”); but it did not crossfade.

Knowing that Unity can be a horrible monster itself at times, Model A figured that it might fare better than Model B. This turned out to be true, as the exact same script worked perfectly for it.

animation.Play(“melee”); doesn’t work either. I mean, it does for Model B, but not Model A. I’ve gone back and forth between the models, looking for some difference, but there is none.

Is there any reason Unity would do this? Besides bias for monsters, I mean. But even if you like monsters, isn’t it better if the victims are animated as they get eaten??

To me, it sounds like you are trying to use multiple bone-sources for animation. Your bone structure must be identical in order to use multiple-animations on multiple humanoids.

A solution would be checking out http://mixamo.com/ and get animations compatible with your humanoids, or wait for Unity 4.0 to be released, which has Mecanim.

PS: Mecanim is amazing. I have fallen in love with it, and makes the animation process 10x faster.

I FIXED IT!!!

There were two problems, and to my surprise, they both occurred within Blender. I’m still not sure why Unity was able to play the first animation, and not subsequent ones, but here’s what I found:

#1. I had keyframes for bones that I had recently deleted
#2. I had a pose-library with two poses in it

After deleting this stuff, it started working, and I am happily coding the animations now :smiley: I’m not 100% sure which one was the culprit, but I didn’t really need either.