[Closed] rotation script controller – multiple values
Hi there,
Im looking to set up multiple rotation controls on one bone object whereby an attribute with multiple sliders are connected to the object.
I need the bone object to rotate by a certain value if slider A is dialled up but if I dial slider B up I want slider A to travel back to 0 and apply the values for slider B.
Is there a handy way to do this using a script controller on the rotation channel of the bone object?
Many Thanks!
Assuming your range is 0-1, slider A value is always 1-B and B is always 1-A?
In that case why do you need two sliders? You need one slider with A on the left and B on the right.
My range is 0-100
Its actually for a proof of concept for a mouth rig, so the sliders will read for example mouthOpen, mouthSmile,mouthSad etc.
I was hoping to setup a system whereby if you have mouthOpen dialled up and you dial up mouth Sad that the mouthOpen will go back to zero as the mouthSad is being dialed, probably easier said than done
I’m messing around with a few different ideas inside a Rotation_Script() on the skin object, and at the moment I have it working except you have to manually dial down any opposing slider
if mouthOpenCTRL > 1 then
eulerAngles 0 0 (mouthOpenCTRL * -.25)
else if mouthSmileCTRL > 1 then
eulerAngles 0 0 (mouthSmileCTRL * .01)
else if mouthSadCTRL > 1 then
eulerAngles 0 0 (mouthSadCTRL * -.1)
else if mouthOooCTRL > 1 then
eulerAngles 0 0 (mouthOooCTRL * -.1)
else
eulerAngles 0 0 0