- Home /
How to use AvatarBuilder.BuildGenericAvatar() ?
I am trying to create a custom Avatar and AvatarMask based on a series of objects that are nested GameObjects with rotations, local positions and so on.
[code]
var avatar = AvatarBuilder.BuildGenericAvatar(tempHandcraftedPrefab, "");
avatar.name = handcraftedPrefab.name;
GameObject go = new GameObject();
UnityEngine.Object o = PrefabUtility.CreatePrefab(bCurrentSheet.BlendedOutputFolder + "/" + handcraftedPrefab.name + "_avatar.prefab", go );
AssetDatabase.AddObjectToAsset(avatar, o);
PrefabUtility.ReplacePrefab(go, o);
AssetDatabase.Refresh();
[/code]
The above code creates an Avatar file, but it doesn't show any bones when I open it inside of the AvatarMask editor window.
I don't know where to go from here. Unity pros - can you give any examples of where you successfully used BuildGenericAvatar?
Comment
Your answer
Follow this Question
Related Questions
Is there no way to create Avatar and AvatarMask for Transform trees? 0 Answers
Character Bone structure and adding weapon to hand 0 Answers
I can preview the animation but in scene it doesn't work 0 Answers
Removing Bone From Hierarchy Animation/Bone Rotation During Animation Problem[Humanoid] 0 Answers
Mechanim Issue 0 Answers