Page 1 of 1
how to use a null as a "magnetized" constraint?
Posted: November 11th, 2011, 12:02 pm
by loreleip
Hi - my activity is animating a cut-out layered puppet. I am looking to use a null as a partial constraint, which will anchor the outermost child of a parented chain (a leg), but not tightly lock it into an X,Y position. Instead, I would like for it to be more like magnet, applying "pull" rather than just fully locking down of the targeted layer.
For example, if the torso of the puppet is the main parent, it could be moved and bring along that leg, while the foot (outermost child) would be oriented/pulled towards that null, like an invisible string is tying it to a stake.
I've been through Dave E's amazing IK code, as well combing thru this site and others, but cannot seem to find help in answering this question...and I can't figure it out on my own.
Any help would be appreciated.
Thanks!
Re: how to use a null as a "magnetized" constraint?
Posted: November 11th, 2011, 9:03 pm
by Dan Ebberts
I assume you've seen this page:
http://www.motionscript.com/design-guide/ik.html
That's pretty much how it works-- if you move the torso, the effectors remain stationary and will act like tethers (unless you parent the effectors to the torso). If that's not what you're after, maybe you could post an example of what it would look like.
Dan
Re: how to use a null as a "magnetized" constraint?
Posted: November 12th, 2011, 8:08 am
by loreleip
hi Dan - I'm so sorry for calling you Dave in my original post. I was referring to you - very sorry.
yes, your script is the "go to," so I have been working with it, but have had some issues that seemed beyond me to resolve, and were interfering with my animation, so I was looking for other ways to consider the situation.
I did a screen capture video of my puppet section, demonstrating my use of the code. If you would review it, I think it is the most direct way of explaining my issue/question.
http://www.youtube.com/watch?v=Yefi6AKP_pE
Here are my questions based on this script and my model response:
1) A "repel" of the foot to the null is happening as the null is dragged around. Is there a way to "attract" only, and not repel?
2) rotation for upper leg only controls lower leg. How to change this to control upper leg instead?
3) Re-positioning/rotating use of the "hip area" as the main parent demonstrates how foot is very much repelled by the null when moved beyond the immediate area of the null. A way to change this?
thank you so very much for your attention!
Lorelei
Re: how to use a null as a "magnetized" constraint?
Posted: November 12th, 2011, 8:37 am
by Dan Ebberts
Hi Lorelei,
Would it be possible for you to zip up your little demo project and send it to me? I think that's the only way I'll be able to figure out what's going on. You can contact me through the main page of my web site.
Dan
Re: how to use a null as a "magnetized" constraint?
Posted: November 12th, 2011, 4:07 pm
by loreleip
WOW - I just found that I missed a portion of your instructions, Dan. I needed to change the "upper = true;" to "upper = false;". ARGH! Now it works really great and it solves all of my desires, hopes and dreams (so to speak.)
Sorry for bothering you with my mistake. The code is awesome, and I'll be sharing it with my animation students @ RISD in Rhode Island.
Thank you, Dan!