- Home /
Do I need Inverse Kinematics? Asking for guidelines to program my own custom script
Hi all, I'm not sure if Inverse Kinematics is what I need for my 2D project. If so, I'm even willing to buy Final IK asset, but first I would like to try programming something by myself.
This is my arm's armature structure (not humanoid):
I want to program one (or more) scripts to be able to, by moving the END empty game object, adapt the shoulder, elbow and wrist angles and the arm, farearm and hand lengths to properly reach the END game object position and rotation. This lasts lengths changes won't be necessary to program because at the end that will be handled by the armature's skinning.
This is a screenshot of what I want to achieve:
*The big body sphere is in the same position than before*
The last piece will be a Suction Cup and my goal is to stick it to a surface by only moving the END point position and rotation by script.
Please, notice that I don't wan't to have an IK Target, and I want the bones of this arm to be elastics. I realized that this two points differ of all Inverse Kinematics solutions I found over the internet, as they have an IK Target to make the END point look at it, and as far I know to extend the arm to reach the target is not the standard. Also, I won't combine this animation with any mecanim baked animation, which I have found ordinary on Inverse Kinematics.
How can I achieve this? Is Inverse Kinematics what I need?
If so, with any standard CCD IK algorithm, how should I deal with the non-target-needing and the always-reaching-target constraint?
If not, could you give me some guidelines to face the programming?
Thank you all!