dragrigidbody script problems

Hello all!

I’m trying to create a game wherin the user can drag and move objects. The standard “DragRigidbody.js” seems perfect for this, as it does exactly what i need (drag physics enabled objects).

The problem is that if the user picks up an object, and uses that object to exert force on another object, it is fairly easy to trash the entire building you just made.

Even if you have a springforce of 100, and weight of the cubes of 10 it is possible to drag one cube that in turn pushes another 50 cubes (which should be impossible…)

Is there a way to limit the force of the spring so that this is no longer possible? Or are there other scripts dat do the same that do not suffer from this problem (I’ve not found any, but I might be looking in the wrong places).

You theoretically set a cap on the force of the spring. Essentially just constantly test the force of the spring to see if it’s above a certain value, and if it is reset it to the cap.

Make the cap public so you can test it and change the value live in the editor.