PDA

View Full Version : Stretchy arm with free elbow 3ds max


skurvensen
08-01-2011, 12:07 PM
Hi
I"ve found some informations about creating a stretchy arm with a free ebow on the forum below:

http://forums.cgsociety.org/showthread.php?t=590979

I tried to follow the instructions but then a few problems came out.
The users nick name whose instruction it was is "gloupi".

And that's what everything is about:
..........
Here is a description of the process to a "Free Elbow Ik".
------------------------------------------------------

Create 3 bones (b01,b02,b03) with an ik limb, and one point.

Unfreeze length of the bones.

Use the point as swivel angle.

Add float list controller on the x position of the 2 last bones, with :
- a float script calculating distance from point to b01 for b02
- a float script calculating distance from b02 to point for b03
- a float bezier as second slot for b02 and b03

Add float script to the float list weight controller (to avoid animation).

Now we need some change handlers :
-----------------------------------------

clearlistener()
gc()

deleteAllChangeHandlers id:#ElbowIk_Sel

when select #($'Point01',$'IK Chain01') changes id:#ElbowIk_Sel handleAt:#redrawViews obj do
(
if selection[1] == $'Point01' then
(
Farm = $'Bone02'.controller.FK_Sub_Control.position.contr oller.x_position.controller
Wrist = $'Bone03'.controller.FK_Sub_Control.position.contr oller.x_position.controller

Farm[2].value = Farm[1].value
Wrist[2].value = Wrist[1].value
Farm.weight[1].controller.script = "1.0"
Farm.weight[2].controller.script = "0.0"
Wrist.weight[1].controller.script = "1.0"
Wrist.weight[2].controller.script = "0.0"
print "Point Select"
)
if selection[1] == $'IK Chain04' then
(
Farm = $'Bone02'.controller.FK_Sub_Control.position.contr oller.x_position.controller
Wrist = $'Bone03'.controller.FK_Sub_Control.position.contr oller.x_position.controller

Farm[2].value = Farm[1].value
Wrist[2].value = Wrist[1].value

Farm.weight[1].controller.script = "0.0"
Farm.weight[2].controller.script = "1.0"
Wrist.weight[1].controller.script = "0.0"
Wrist.weight[2].controller.script = "1.0"
print "ik Chain Select"
)
)

deleteAllChangeHandlers id:#Ik01

when transform $'IK Chain01' changes id:#Ik01 handleAt:#redrawViews do
(
$'Point01'.pos = $'Bone02'.pos
)

deleteAllChangeHandlers id:#Elbow01

when transform $'Point01' changes id:#Elbow01 handleAt:#redrawViews do
(
Farm = $'Bone02'.controller.FK_Sub_Control.position.contr oller.x_position.controller
Wrist = $'Bone03'.controller.FK_Sub_Control.position.contr oller.x_position.controller

Farm[2].value = Farm[1].value
Wrist[2].value = Wrist[1].value
)

Feel free to try and comment.
If needed i can post an example file.
............


I create 3 bones (b01,b02,b03), set the IK, do not freeze the bones but add a float script and a bazier under the x position of the 2 last bones in the float list controller. But what then?
How to add that script? What informations should I put into the the float script?

CGTalk Moderation
08-01-2011, 12:07 PM
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.