Centripetal Movement and Avoiding Stretch in 2D Ball and Rope Object

I’m trying to implement a ball and rope object into my game. I currently implement it as an anchor point, a rope with a skeleton, and a ball object. These all have rigidbody2d, hinge joints, and a distance joint from the ball to the anchor. I have touch controls that let me drag and drop the anchor point. I was expecting the rope to respond to the physics generated by moving the anchor, thus allowing me to swing and rotate the ball since everything is anchored together with the hinge joints. However, I get very inconsistent movement. The rope stretches despite the distance joint, and it never seems to generate enough force to do a full loop, no matter how much I try to alter the gravity and mass settings. Does anybody have any idea how I can implement a non-stretching rope that can be swung around in loops?

You might want to take a look at this and the accompanying project.

If you’re changing anchor points too much, the joints will need time to get back into constraints i.e. it has to be physical motion. You should avoid changing anchor points though if possible.

There’s solver interations there for a reason too; the defaults can be increased to give the solver a better chance of producing a good solution; especially true if you’re making it hard for it to solve it.

Thanks, that video was very helpful for visualizing the benefits of the distance joint. My game aims to control the weight at the end of the rope by moving the beginning of the rope and not the weight itself. You’re recommending I don’t move the anchor. Is there a better way to implement this than just making an anchor point and having the anchor point move with touch controls? I’ll give the increased iteration a shot and will report back.

It’s hard to visualise what you’re doing specifically and the end goals simply from your initial description so it’s hard to recommend another way.