[Closed] bones and controls
Hey there,
[img] http://www.community3d.com/stuff/hier.jpg [/img]
So, the hierarchy above represents something I'm trying to do with MaxScript. The bones are initially laid out without the pointHelper or curveObject. I select bone3, run my script, and it inserts pointHelper and curveObject -- curveObject drives bone3 at this point.
Really, if I could have the curveObject, which is an Editable Spline, somehow directly on bone3, I think my problem would be solved. If I can't get curveObject directly onto the bone, then here's my question:
Once I drive position of bone3 with curveObject, bone2 no longer stays aimed at bone3. How can I drive bone3 with curveObject and have bone3 maintain it's relationship with bone2?
That make sense?
Thanks,
Alec
Just in case you are using NURBS curve I’m going to tell you don’t, they are very slow, just don’t touch NURBS at all in Max.
How are you driving bone3 with the spline object?
Hey there. Nope, no nurbs curves, just splines. Initially, I’m just using the circle shape as my controller (keeping it simple).
So I’m driving the bone with the circle shape via wiring up something like this:
paramWire.connect circle.rotation.controller[1] bone.rotation.controller.eulerXYZ.controller.rotation_list.controller[1] “X_Rot”
I do this for all 3 axes in rotation and a similar setup in position – with a position_list inside of a positionXYZ. The controlled bone follows along just fine, but it’s parent is no longer behaving the way it should – rotating in response to it’s child’s translation.
What I’m seeing now is that when I translate a child bone via the circle shape, the parent bone follows in the x-axis, but not the y or z.
I’ve tried making the connections programmatically as well manually with the same results.
Attached is an image showing what I mean.
Any ideas?
Thanks,
Alec
No translations —–v
with translation —–^
OK, the bone movement comes from the stretch factor (scale, x-axis).
I’ve confirmed that Auto-Align is on for the parent bone…
I thought that it was having problems because the parent’s rotations were controlled by a different circle curve, but even when I only apply the curve control to the child, I end up with the same results.
I’m not even changing the child’s position in the hierarchy. I’m just adding the control curve and it’s parent into it.
This is just so weird.
Alec
Did you wire the position of the bone to the control as well? and I can’t see that paramWire line working as it needs named paremters passed to it.
Can you send me a file?
You can use lookAt_constraint controller on the parent bone to force it to look at the circle
or you can copy the base object of the circle onto bone3 to make it look like the circle.
To copy the base object you can go to the curve editor and find the base object on the buttom of the stack or you caqn use this code:
$<bone3 name>.baseobject = $<curveObject name>.baseObject
Hey there. Basically, the solution (Thanks Paul!) is to take the controls out of the bone hierarchy and drive the bones from a separate control hierarchy. That way, the relationship between the bones isn’t interrupted and I end up with a cleaner, more manageable structure.
So far so good.
Thanks again for the input.
Alec