- Home /
Importing animations using a single model containing all animations
I have a single model containing all animations, not multiple model files.
And I have split all animations. Like figure
Next I set animations element is right? Like figure
I want to write a code like this, eg:
"wait" : start game with default/no any animations
"lurd" : continue pressing down "up" and "right" (if no continue pressing will return wait)
"up" : continue pressing down "up" (if no continue pressing will return "wait")
I can't find any information to reference. Resources in the network are using multiple model files.
How do I write the code?
And I have two files. The one is no animation, the other is have animations.
When done the code...Which I should put into?
Thank you very much!!!
Answer by Owen-Reynolds · May 10, 2011 at 07:12 PM
There are code samples and an explaination of setting up wrap/playOnce transistions using layers at http://unity3d.com/support/documentation/Manual/Animation%20Scripting.html. For example, explains about setting wrapmode to Loop.
The code there works just for the "all animations in one long sequence" method. In other words, animation.Play("lurd") will pick out the Lurd frames just fine.
The rest is just getting the IFs written correctly.
Your answer
Follow this Question
Related Questions
importing a character with no BIP 1 Answer
Unity won't animate Maya Model 1 Answer
How do I use Makehuman models with Mecanim? 0 Answers
Animated character plays in the preview but not in the scene. 2 Answers
Help, can't import animation into unity 0 Answers