Hinge Joint Limits 2D in C sharp
I am making a game which includes a character balancing on a object when the hinge joint 2D reaches the lower angle or upper angle limit i need it to (do something). The only problem is i dont know how to access the hinge joint 2D limits in C# and can't find anything online or in the Unity manual can anybody help?
Comment
Answer by Blablablas · Sep 02, 2017 at 09:02 AM
HingeJoint2D.jointAngle should return the angle of the joint. Try checking if HingeJoint2D.jointAngle is at the desired angle (limits.min or limits.max).