Hey guys, I've got most of this game worked out, and it's actually functioning great, but I'm trying to add another control scheme and I can't seem to get it working... In the game, you're arms are attached to the body via hinge joint, and you press Left/Right to rotate them around using this type of action:
Now, I also set this up for use with my PS3 controller, as such:
What I want to be able to do, is instead of just adding to the motor's velocity, I want to be able to rotate the arm to point exactly where the analog stick is pointing. The code that I can use that works fine for a regular object is this:
The problem is, is when you apply that code to the arms, which again are attached to the body by a hinge joint, the whole character just goes absolutely haywire...
Here's a pic so you can get the idea of what motion I'm trying to get at:
Thanks so much for any help!