Notifications
Clear all

[Closed] Changing the length of CAT bones via script

Hi

I’m trying to match a CAT rig to a std bone rig but I am having issues with the bone lengths.

For example if you select an Arm or Leg bone on a CAT rig with a units ratio of 1 in setup mode and try

$.length = 10

The bone will appear to have scaled in the viewport but the length value won’t have changed in the modifier panel. As soon as you move that bone it will revert to it’s original length.

How do I set this length permanently?

Cheers

7 Replies

after that I can animate as per usual…with huge head and looooooong arm
(just using a Base Human CAT rig)

(What I found odd was, I didn’t even have to be in Setup Mode, I can be in Anim Mode on an already animated dude, change his limb lengths…just works)

Hi vusta

Thanks for taking a look. Can you just confirm for me;

If you select the Upperarm (in setup mode) use $.length = 10

Does the length value actually change in the modifier panel? (It doesn’t for me)

If you then just change the position or scale (not rotation) any small amount on that bone does it not just flip back to it’s original appearance? (It does for me)

I’ve also checked this in animation mode where again the length value wont’ update in the modifier panel but here it won’t flip back visually in the viewport while still in animation mode.

(I’ve tried this in max 2017 and 2016)

yeah all works as expected…i tried in the listener both height and length…and it will update the modifier value and actual physical size…

No i haven’t tested moving/scaling, just rotating the bones…will do when have a minute…

(don’t quite see the point in scaling tho, yes in setup mode you’re likely to move the bones around to adjust to your mesh…but scaling…that’s just asking for troubles IMO)

Okay for arms and legs you need to use .controller.Length not .Length

Clearly needed to sleep on that one.

Hey yes you’re right about scaling, it was more to demonstrate that the value wasn’t really what it claimed to be and would revert on updating.

I assume the .controller.length is to do with just how CAT allows you to position the rig in setup mode before animation.

Thanks for taking a look though.

yeah i recorded my actions and saw that it spat back at me controller.length in the listener, however i tried your $.length anyway simply to see what happens and it worked.

hmmm…looks like for non-arm/leg bones…doing $.length=xxx will update the modifier, physical size and will remain active, even with ‘move’.

for arm/leg bones, the modifier value doesn’t update, physical size updates, rotate is still ok but as soon as I move the bone it snaps back to orig size.

dunno what I did yesterday…maybe I tested on the Head and that worked fine…and also the arm, but i rotated the arm yesterday, not moved.