Skeleton3D Bone Hierarchy

Godot Version

4.3

Question

I’m trying to import a rigged robot arm model from Blender as GLTF. It is constructed of separate meshes for each part of the arm with an armature of bones with the meshes parented. In Blender I can then rotate a bone and all the child bones and attached meshes translate automatically observing the hierarchy.

When imported into Godot 4 the scene has a flat structure of bones.
If I rotate a bone in GDScript with set_bone_pose_rotation, just the single bone/mesh moves detaching from the upper stages.

If I instance the scene and move each BoneAttachment3D into a hierarchy I get warnings about parents not being Skeleton3D but rotating the bone in the editor does appear to translate the upper stages correctly. But trying to do this at runtime in GDScript with set_bone_pose_rotation results in no rotation or translation at all.

Looking at the various examples of skeletons in Godot, every one is using the animation player and the bones all have the same origin at 0,0,0.

I can’t find a description or tutorial that describes how Godot expects a bone hierarchy to be setup or how its expected to work.

Is anyone able to point me in the right direction?

Thanks

Ah figured it out. I had assumed the bone hierarchy was represented by the scene tree. Its not, its visible against the Skeleton3D node in the inspector which confused the issue.

The problem was caused by the origin of each mesh being at 0,0,0 in Blender. Solved it in Blender by placing the 3D cursor on each bone start point and then setting the parented mesh origin to the 3D cursor. That way each mesh rotates around that point. It doesn’t matter to Blender but does to Godot.

Now each bone rotates its mesh correctly maintaining the translations for the subsequent bones.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.