public static void setTransform(Bone bone, Vector3f pos, Quaternion rot, boolean restoreBoneControl, Set<String> boneList) {
        //we ensure that we have the control
        if (restoreBoneControl) {
            bone.setUserControl(true);
        }
        //we set te user transforms of the bone
        bone.setUserTransformsInModelSpace(pos, rot);
        for (Bone childBone : bone.getChildren()) {
            //each child bone that is not in the list is updated
            if (!boneList.contains(childBone.getName())) {
                Transform t = childBone.getCombinedTransform(pos, rot);
                setTransform(childBone, t.getTranslation(), t.getRotation(), restoreBoneControl, boneList);
            }
        }
        // return control to the keyframe animation
        if (restoreBoneControl) {
            bone.setUserControl(false);
        }
    }
Updates a bone position and rotation. if the child bones are not in the
bone list this means, they are not associated with a physics shape. So
they have to be updated

@param bone the bone
@param pos the position
@param rot the rotation
@param restoreBoneControl true &rarr; user-control flag should be set
@param boneList the names of all bones without collision shapes (not
null, unaffected)
jme3-jbullet/src/main/java/com/jme3/bullet/control/ragdoll/RagdollUtils.java