Multiple Child Of Constraints with Multiple Animations

Hello all! I’ve a humanoid IK rig that has the ability to hold several different types of 2 handed weapons. Depending on which weapon animation is selected, I have “Child Of” constraints set to 1 or 0 for each hand (inserted as a keyframe in each animation). For example, when wielding a claymore the sword itself is a child of the left hand and the right hand is positioned and made a child of the right hand. This way the sword and right hand follow the left hand wherever it moves. The opposite is all true when I switch to a different weapon (right hand leads, left hand follows).

My problem is that when switching from 1 set of animations to another, only the most recently changed animation works properly. That is to say, if I have a completed set of claymore animations, and add a katana animation tomorrow, the katana will work perfectly, but the claymore will have odd behaviours such as the child hand (and limb) bouncing strangely during animation. This is easy to remedy in blender, but becomes problematic when exporting to an FBX, where the problematic hand seems to return to its default position for a frame (usually the very first frame). If this is at all confusing I will add my files later today and a video of my problem.

Thanks!

My .blend file:

A video of the problem taken from FBX Review since it doesn’t show so well in blender:

Some images showing what I’m talking about:




Figured it out. In case anyone else ever has the same problem, here’s what I did:

I created additional bones in the humanoid skeleton for each weapon type. The skeleton for each weapon was set as a child of the appropriate bone in the humanoid mesh with a copy location/rotation constraints.

For a particular weapon animation, I would set the corresponding bone as the parent of both hands (keyframed of course). Apparently, these are called attachment bones and is the preferred way of doing such a thing.

This is probably common knowledge, but I’m fairly new to animating.

Thanks a lot for the autoreply, it helped me a lot! :smiley:

No problem. This is still a work in progress, and the developer has changed the way he wants things done. It’s no longer an issue for me personally, but I’m sure someone else will find it useful someday.