Home Website Youtube GitHub

Is it possible to create IkFk matching on chain_01 component?

Hello :slight_smile:

I’ve been working on a rig that needs to have IkFk matching on a chain_01 component. I tried using the same code structure that can be set up with the arm/leg components in the picker. I couldn’t find anything other than that online. I’d also love to know if this can be done with other components.

Here’s the code I’m using:

from mgear.core import anim_utils

if not __INIT__:

    anim_utils. ikFkMatch_with_namespace(__NAMESPACE__,

                                        "chain_blend","C_spineUI0_Control_ctl",

                                        ["C_trunk0_Fk_trunk_ctl", "C_trunk0_Fk_trunk_1_ctl", "C_trunk0_Fk_trunk_2_ctl", "C_trunk0_Fk_trunk_3_ctl", "C_trunk0_Fk_trunk_4_ctl", "C_trunk0_Fk_trunk_5_ctl", "C_trunk0_Fk_trunk_6_ctl", "C_trunk0_Fk_trunk_7_ctl", "C_trunk0_Fk_trunk_8_ctl", "C_trunk0_Fk_trunk_9_ctl"],

                                        "C_trunk0_Ikcns_ctl","C_trunk0_Upv_ctl"

                                        )

Hey, @gasmar
Had you tried with the other chain components? I think there’s one that gives you ik/fk switch already.

Hi welcome. I took the liberty of editing your post. Put code between triple backticks ```, so it formats as code.

Apologies for taking a while to reply. So I tried to set this up but it’s not quite what I’m looking for. I checked the other chain components and none of them seem to give me the option to add matching functionality.

Unfortunately, I can’t upload a video of this asset due to an NDA, but essentially it’s an elephant trunk that I need to be able to stick to the floor while it moves the head. I managed to make this work by using a chain_FK_spline_variable_IK_01 component and making a series of control_01’s to set up the space switching. However, it would be nice if the animators could match between the switching. That way, they wouldn’t have to use some locator magic to, get the trunk to stick to the ground and then lift it back up while following the head.

Is this something I could set up with mGear matching?

Bumping this up for some potential feedback :slight_smile: