#animator problem
1 messages · Page 1 of 1 (latest)
k
ignore the missing warnings down there, those dont have to do with the problem. I have idle0 in the animator but it is not shown here
"idle 0" is the name of the animator state
yes
This is not the name of the animation clip that the animator state uses
"idle" appears correctly in that list
no
There is no idle 0 animation clip
I litterally circled it
you can name an animator state whatever you want
its in the animator
That is an animator state.
An animator state is a position you can be in the animator controller.
its a clip
I know how the animator works.
Do you want help, or do you want to argue with me here?
me too, im telling you its NOT an empty animator state
I did not say it was an empty animator state.
I said that "idle 0" is an animator state.
I dragged a clip not an animator state in
It was created when you dragged in the "idle" clip
You can't drag an animator state in.
When you drag a clip in, a new animator state is created.
By default, the state is named after the clip
Since you already had a state named "idle", it had to change the name
hence "idle 0"
The animator state named "idle 0" uses the animation clip named "idle"
If you drag the clip named "idle" in again, you'll probably get a state named "idle 1"
look, i dragged this animation clip
it is called idle 1 because there is another idle animation
Yes.
You now have an animator state named "idle 1"
It references an animation clip named "idle"
The Animation window lets you look at animation clips used by an animator.
It does not show you animator states.
then why do all the other animation clips show on here?
because it shows you every animation clip used by the animator.
THIS IS an animation clip, its not a state, this is a CLIp
i put that clip in the animator
what is "this"?
the animation clip circled in this screenshot
Are you talking about this?
it works on the other armature but not this one called Noel
yep
Then yes. That is an animation clip.
See
You dragged it into the animator, creating a new animator state.
This is an animator state named "idle 1"
It references the "idle" animation clip
Therefore, "idle" appears in the list of clips you view in the Animation window.
"idle 1" does not appear, because there is no animation clip named "idle 1"
but i just dragged it in
Yes. You dragged the animation clip into the animator.
This produces a new animator state.
ok
These are not animation clips.
so how do i get it to show and work then
all of those are animation states that reference the clip right?
Yes: basic animator states reference a clip
oh ok
they can also be blend-trees
Start by looking closer at the animation window.
You have a lot of missing channels there. Make sure that the ones that move the body around aren't all missing.
i said for those to be ignored, they dont have anything to do with this
those are bones i dont use
That's why I'm asking you to check that the bones you are using are working right.
There should be a deeply-nested series of channels that are all free of that "Missing!" warning
okay, good, the Run clip is working right
all clips work right
thats how i did the game
it plays different clips for running
now, make sure that you don't have any animator components attached to any other part of the character
those could interfere with playing the animation
Right. There should only be one of those in the hierarchy for the character.
yes, theres only one
ok
and if you have the character selected, you should see a blue bar under one of the animator states in the Animator window.
e.g.
If you select the character and click "Preview" in the Animation window, does anything happen?
It should preview the currently-selected animation.
Yes, ik this. Basic animator stuff.
Does it work?
Idle1 doesn’t show so I can’t play it
Does the animation preview correctly?
So every other animation clip will show up properly when you preview them, but the "idle" one does nothing?
Every animation plays correctly, I can’t get it to play idle1 because it doesn’t appear in the animation tab, and even if I use a script it does nothing
.
You want to enter the "idle 1" state.
You need to do something to make the animator transition into that state.
You can just set it as the default state so that it plays automatically.
(just for the sake of seeing it playing)
From code, you can directly enter any animator state by name.
animator.play("idle 1");
this will immediately transition into the "idle 1" animator state.
It doesn’t do anything when I script that one to play
Look at the Animator window while your script tries to do this. Does it wind up in the wrong state?
If you have a transition coming out of "Any State", then that transition can always activate. This could be making you leave the "idle 1" state.
No, it tries to play idle1 but no animation plays
Idle1 is out in the open, nothing is interacting with it
Does this mean that the blue progress bar appears under the "idle 1" state?
Yes
If you turn on "Preview" in the Animation window and select the "idle" animation clip, does no animation appear to play?
I’ve shown you a screenshot of it not being there
The "idle" clip is in the list.
There is no animation clip named "idle 1". You have not shown me any screenshot in which there is an animation clip named "idle 1"
These are all animation clips. None of them are named "idle 1"
It changes it to idle 1 because there’s already one in there called idle
These are all animator states. One of them is named "idle 1"
you've told me you understand the difference, but it really sounds like you don't
I renamed the idle to something else and then it appeared in the animation window now. But the problem is that everything says missing
No
Ok wait
I renamed the idle I dragged in to something else, then it appeared
(I named it idleURMOM, I know, a silly name, but when I dragged it into the animator it actually showed in the list)
Then all the yellow warnings appeared
All that matters for the Animation window is which clips you're using
The names of the animator states are irrelevant
Yes, the clip idleURMOM appeared there
So, show me the animation window with the clip you want to use selected.
Expand it so that you can see a lot.
oh, I meant to expand the entire window, so we can see more
I'm specifically interested in what's at the top of the list on the left side
A view like this would be ideal.
Scroll that list on the left to the top.
Ah, okay, this animation is very specifically looking for an object named "Catrine"
other clips depend on it being named "NoelArmature" specifically
One option would be to duplicate the animation clip and then fix the names
You can rename a channel by hitting F2
like so.
If all of these animations come from .FBX files, you could also just edit them in Blender so that the top-level bones have the same names
e.g. rename them from "NoelArmature" to "Armature"
and from "Catrine" to "Armature"
Doing the same to the other bones to make them all match would also be helpful.
(unless those parts are character-specific and can't really be made uniform)
Ohhhhhhhhhhhhhh
Generic animations demand that the armatures are exactly the same
The problem is that I would have to create another animation clip for every character, that’s what I have already so I wanna fix that
Humanoid animations are much more tolerant in that regard.
If your armatures are roughly humanoid shaped, it would be an option
What do I do with humanoid then
Humanoid animations recognize common bones, like the hips, chest, lower arms, and ankles
You set up an avatar on each character (which is generally completely automatic), and then animations from one avatar can be retargeted onto another
in your case, you wouldn't really be using the retargeting, since the skeletons are all the same shape
but it would smooth over the different names, probably
If you can just edit these things in Blender, then I'd suggest going and making the bone names consistent
That'd be the simplest thing to do
Ok, I had the idea of an avatar, but every time I do that on a humanoid, it just has the default avatar pose and gives me a binding warning
Every name is the same
(except for the top level armature)
also, note that since you duplicated the animation clips out of the model assets, you would need to delete these clips and then re-import the models after changing the armature names
You can just reference the clips directly from the model assets. It's what I do now.
If you need to edit them, select the model asset and go to the "Animation" tab. You can edit all of the clips there.
For every character I have the same animation clip name supported for that character, so in this case I’d need to make an avatar for it to work right and switch the rig to humanoid
right. If the skeleton has the wrong shape, though, you might have to do a lot of manual setup for each character
depends on what kind of warning or error you got here
You'd certainly get a T-pose if you just switched the characters to Humanoid and did nothing else, mind you
Binding error, something about humanoid clips
the animation clips you duplicated out would still have been imported as Generic animations
and the generic animations aren't allowed to touch the humanoid bones
I think I understand
You can use both generic and humanoid animations on the same animator controller
But the generic ones will have to only touch non-humanoid bones
You see, the animations inside the Fbx can get changed by the settings, I already duplicated the generic ones so I need to do the humanoid ones then this should be fixed
Right. The animation clips that are sub-assets of the model asset will get updated automatically
That's why I don't duplicate them out anymore.
if I make changes and re-export the model, everything updates automatically
I think I finally understand! Thank you. Duplicating them is the best way to put them in the animator actually, for me at least
Thank you! I am pretty sure I know the problem now thanks to you, you are someone who understands and actually has patience with me and didn’t give up, is there anything I can do for you maybe?
glad to hear. and nah, i'm good (:
just make sure you ask for clarification if something isn't clicking; we got hung up on clips and states for a long while there.
Yeah
So for future understanding if I run into another animation problem, dragging animation clips into the animator makes a new animator STATE that references the clip, correct? When it is run it runs the clip
Right.
An animator uses an animator controller
An animator controller has one or more layers. Each layer holds animator states
Animator states can transition to other animator states.
An animator state can just play a clip, or it can be a blend tree that combines many clips or blend trees
The animation clip is what actually contains the animation data.
Also avatar masks, an avatar mask can basically help blend two animations together
An avatar mask limits what a layer affects
The mask has two parts
One is the humanoid mask. It controls which humanoid parts the layer is allowed to control
The other is the transform mask. It controls whether specific transforms can be controlled. That's the only one that works for generic animations.
Whenever an animation that has the legs staying still but effects the top part, you would use an avatar mask to continue the animation on the legs if they are running
Right.
Ok
I usually make the first layer be the one that plays the locomotion animation
e.g. walking
and then other layers use masks to affect just certain parts
So once I set up animators I will finally be able to correctly do the mask
Yeah I did that for a stumbling animation