Hello everyone!
This is my first so I will introduce myself briefly:
Australian, 26, former Flash artist/programmer, dabbled in Indie game dev for a long time (various forms of Basic).
I’m fairly new to Unity and OOP but I am happy that I am picking it up relatively quickly.
Now to my question!
I am attempting to make a robotic arm as a bit of a learning exercise.
I want it to have a few key bindings, each one making the arm move to a particular position.
Currently I have hinge joints and I can make it wave from one side to the other by applying torque
to the joints, but whilst that is somewhat of a success (and highly amusing) it is not the desired result!
The desired result -
#1 - Pre-determined angles for the joints that they will begin to move towards by forces applied through
the script when certain keys are held down.
#2 - A default position that the arm will forcibly move towards should there be no keyboard input.
#3 - The animation is created through the script to allow the rigid bodies to interact realistically with the environment.
#4 - If the moving limb is blocked then it could not complete the motion but will continue to try to so long as the key is
held down, or it may glance off another object and be forced around it. Whatever the join position, it will always try
and move towards it’s target, no path finding, just current position to target.
#5 - Joints MUST be able to account for rotation also. There will be a grabbing hand on the end of the arm eventually
and making a gigantic slapping/backhanding device is not the desired result (although again, probably hilarious)
I drew something to try and illustrate the “current position to target position” movement.
I know I need to use something other then hinge joints for this, but I am unsure what (configurable joints seem likely).
Any help is appreciated, I will keep chipping away at it myself but after reading through some of the other replies on here I
am sure someone knows how to go about this.
Thanks!