How to get the rotation of a bone at a certain time-frame of an animation without playing it?

My problem is that I have an idle-combat animation on my character in which the root bone is rotated (the pelvis) to give it a sort of boxing stance, then I animated a punch on top of that rotated root bone, which looks good when standing still.

I figured I would just play the punch on layer 1 (with idle/walk on layer 0) and add the mixing transform to the spine to get it to play independently from the leg animations and I didn’t really think about the root bone being rotated, but while running it rotates the upper half of the character so he punches off to the side.

Now I was thinking that a possible solution would be to get the rotation of the pelvis(root bone) from the upper layer without actually playing it if it’s at all possible and then just apply that rotation to the spine(mixing transform).

I was also thinking if this isn’t possible, i might be able to just make another instance of the character (without rendering) and play the animation at the same time without the lower layer/mixing, then grab the bone rotatation from that one.

Is there a good solution for this that anyone knows of, or a proper way to animate it in Max that would work around it?

If you want to see the issue, here’s the web-player. Hitting number 1 and 4 while moving are the best ways to see the problem in action.

Animation.Sample() is made to do this sort of thing. In the blank line after the Sample command, you can read off the rotations.

Of course, Sample sets values using the usual priorities – the mixing transform will still cut out hip rotations. [untested from here:] To get around that, temporarily disable the mixing transform, Sample, read the hips, then re-enable. Or, use your dummy object w/skeleton idea, with AddMixing to move only the hips (to save time.)