Download

PhysicsConstraint, Angular Orientation Drive rotation issue !

Anybody ever used the PhysicsConstraint Angular Orientation Drive to drive precise rotation before ?
I’m finding you can’t input anything above 180 degrees or the ration gets smaller and smaller the further over 180 you get. If you put 360 you get no movement what so ever so i’m thinking this method has fundamental issues that I can’t find explained anywhere ?
I’ve looked a the physx documentation and it mentions some things about gimbal lock etc but not really anything conclusive, also some issues with singularity at particular angles that sounds quite fun.
I’m trying to make a joint spin around an axis with the press of a button, say one press is one full rotation and two would be 2 rotations. I need to keep physics active the hole time and also under the force of gravity. Can anybody thing of a way I can achieve this, perhaps parenting some kind of kinematic rigid body ?

It sounds like the joint is being driven through the shorter of the two arcs, once you get over 180 degrees. When you get to 360, the solver realizes that the joint is actually already at 360, which is the same as zero, so you won’t see any motion at all. I think you could achieve your goal by setting the drive position ‘ahead’ several degrees, with each frame, for a number of frames: first frame +10 degrees, second frame add another 10 degrees, etc., until you hit the goal.