Now the gameobject below had a man with pink hat as the avatar (it has a ton of components on it, all I want to change is the avatar). I tried to replace it with the skeleton avatar, but it did not change.
As you can see above I changed it to also use the Skeleton@SkinAvatar but that change is not reflected in what is showing on the screen. It is still showing the old pink hat man avatar. Any ideas why?
The Avatar has nothing to do with the visual mesh, it defines stuff about how the bones are animated.
If you want to change the mesh you can go to the SkinnedMeshRenderer(s) on the children of that object but if the bones are at all different between the models then you won’t be able to simply swap one for the other.
I always put the model as a child of the mechanical components (collider, rigidbody, etc) so that I can simply delete the model and drag a new one in without losing anything else.
ah ok thanks a lot. im gonna give that a go. does the animator still go on the parent with mechanical components, or does it go on the child with the model?
also in practical terms, lets say the player can choose from a number of different models. do you have each model as a prefab and then just add the relevant one as a child to your main mechanical pref at runtime?
That’s how I’m doing it in my current game, but one of the obvious drawbacks is that you can’t simply drop an enemy prefab where you want it in the scene (because there is no enemy prefab, it’s a Creature + stats + model that you need to put together). For some games (like mine) that isn’t a problem, but it might be inconvenient for others like say Dark Souls where you would want to see the enemies in the scene as you are building it.
Slightly old subject. I was going to write a follow-up question but this morning I did achieve this result of switching avatars (and everything else) while letting Animancer do its thing.
The AnimancerComponent and character logic is in the parent, and all of the shown characters are self-contained bundles with their own Animator, SkinnedMesh, bone hierarchy, and a small class that forwards the OnAnimatorMove() calls (and known animation events like FootL, FootR, etc.) up to the parent. I can switch bodies even with multiple layers of Animancery and IK going at once.