- Home /
Question by
samth · Feb 18, 2019 at 02:23 AM ·
2d2d-physicshingejoint2dlimits
HingeJoint2D.jointAngle flips between two values based on rotation
I have two rigidbody2D's joined with a HingeJoint2D. If I rotate them so that they stay relative to each other, such as by rotating a parent gameObject, the jointAngle property of the hinge joint will suddenly change (by -360) at a certain rotation. This is problematic because it affects how the hinge joint reacts to angle limits that are set. In my case, if an object starts out at a specific rotation in the scene, the joint behaves in an unexpected way as the jointAngle is outside of the limits I've set, and it snaps back to within the limits. In this example, it flips briefly from 20 to -340. Any ideas on what's causing this? Thanks!
2019-02-17-20-49-14.gif
(385.2 kB)
Comment