Home Website Youtube GitHub

Define chain aim axis


I’m trying to build a chain but I have a specific aim axis that I require. The spine below the chain bends on the X axis but the chain builds in a way that is inconsistent and bends on the Z axis. I need to find a way to define the chain component so that I can decide how the “local rotation axis” of the controls are set up.

I would like to take a guess and say it’s in the component’s init.py around line 23:

    class Component(component.Main):
    """Shifter component Class"""

    # =====================================================
    # =====================================================
    def addObjects(self):
        """Add all the objects needed to create the component."""

        self.normal = self.guide.blades["blade"].z * -1
        self.binormal = self.guide.blades["blade"].x

EDIT: Nope, maybe it has to do with this part of the code but it would seem the change needs to happen at a more fundamental level. In the end I was forced to build my own chain with “control_01” components as Shifter respects the orientation of the guide in that case.

Hello @mwessels

Sorry for the late reply, I am on vacations :stuck_out_tongue:

The optional axis orientation is something that has been requested a few times, but never take the time to evaluate how long will take to update it.

Should be possible to change the code in a specific component to get the desired orientation. But is more involved that just changing the joint orientation, because needs to change the elements in the rig.

Ideally the change should be done only for the joint orientation changing addJoint method


And later expose the options in the settings.

This looks like a limitation but is a heritage of the original design where the joints are just for skinning and the joints were scattered in the rig hierarchy.

Not sure if this information is useful. But I hope that this make sense :stuck_out_tongue:
I should update this in some point :wink: :


1 Like

Hello Miquel !
Do you have any news about it ? :slight_smile:
Because in the game template, controls of the spine are Y forward and not X like other controls…
Of course I could make my own module but I like to have mgear update on default modules :grinning_face_with_smiling_eyes:


i have also had the same “problem” in the past

1 Like