3DS max wire expression issue

Become a member of the CGSociety

Connect, Share, and Learn with our Large Growing CG Art Community. It's Free!

Thread Tools Display Modes
  05 May 2011
3DS max wire expression issue

Hey everybody,

I´m currently encountering a "problem" on rigging a character with wire expression parameters. Here´s the situation:

I´m using Max 2011 as application and CAT as a rigging template. What I would like to achieve is a system of adjustment bones to finetune the character´s mesh deformation by help of wire expressions.

For simple joints (knee) this is no problem. I use an ExposeTm to read the local rotation from the CAT bone and then wire the data into the adjustment bones position and rotation (something like Euler_Z*9 for the adjustment bones x position). Knee bones rotation is connected to the adjustment bones x position, everything runs smooth.

So far, so good, here´s my problem. For more complex joints, like the hip joint (Articulatio coxae) I was planning to use 4 adjustment bones surrounding the hip joint. When the leg rotates forward, joint 1 is activated and moves according to the wire parameters, while bones 2 to 4 are non-active, when the joint moves backward, joint 2 is activated, while bones 1, 3 and 4 are non-active, and so on.

I was planning on using an if clause as a wire expression. Currently it looks like this for the first adjustment bone´s X position:
Quote: if (World_Euler_Z > 0) then




What happens is as soon as the hip rotation goes over 0 degrees the adjustment bone jumps to a certain position and then stays there (which is bad) until the rotation goes below 0 degrees where it jumps to 0 position (which is good).

Question: How do I fix this? Maybe I need something in the wire expression so on each new frame the position is calculated anew (Like on framechange do (insert code here)). But I could be wrong again. Can anybody push me in the right direction, as I´m running out of ideas right now.

Cheers and thanks in advance


BTW: I put this here because I guess this is a problem often encountered in rigging, regardless of it being something more of a 3DS/Max script problem
  05 May 2011
Have you tried using limit controllers?

Wire the controller up normally like you did with the knee (no if statement) Then add a float limit controller to the wired track. You can then specify upper and lower limits so, if your CAT rotations go outside these limits, the wire controller will cease to have any effect. As a bonus you can ease into these limits so the adjustment bone doesn't come to an abrupt stop when reaching it's min / max limits.

Hope it helps

  05 May 2011
Whil not being able to give you a solution to your problem, I've done setups very similar to that in the past but have found debugging wire parameters to be a gigantic pain in the ass!

What I do instead now, is to use float expressions instead of wires on the bone i want to drive, then create a scalar in the expression which points to the bone I want to be the driver. Then I can create an expression in parent space.

Then if I encounter issues, I can open the expression and use the debug window to see what my driver bones rotation is and also what the end result rotation on my driven bone is.

More often than not when I encounter issues like this its because of something giving different values under the hood compared to what I'm seeing in the UI. Maybe it's something as simple as a degree to radian conversion (been a while since I've used wires though so not sure)?
Matt Rennie
Sr. Character Rigger
Rockstar North
  05 May 2011
3-2-1... Lunch break

And here are the first solutions. Wow guys, that was quick.

@Duncs: Okay, that sounds like a good quick workaround, I will definetly check that out and give you a heads up if it worked out right. Thanks

@MattRennie: Yeah, Wire parameters are a pain in the ass. Sometimes I wish myself back to the times when I worked on Maya and could use driven keys for work like that. I will keep your solution in mind, although probably not for this project, as time is running out. Thanks to you as well.

Cheers and back to work


*Edit*: Duncs, it worked. Thank you very much for giving me a nudge in the right direction

*I guess the thread can be closed by an admin*

Last edited by dunkelzahn : 05 May 2011 at 12:04 PM.
  05 May 2011
Thread automatically closed

This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
CGTalk Policy/Legalities
Note that as CGTalk Members, you agree to the terms and conditions of using this website.
Thread Closed share thread

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Society of Digital Artists

Powered by vBulletin
Copyright ©2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump

All times are GMT. The time now is 12:01 AM.

Powered by vBulletin
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.