breakForce and infinity not doing what doc states

The documentation at: Unity - Scripting API: Joint.breakForce

states that "The break force can be set to Mathf.Infinity to render the joint unbreakable. ",

but if I do exactly as the documentation states: hinge.breakForce = Mathf.Infinity;

then I get the following error:
“Joint2D.breakForce assign attempt for ‘Capsule’ is not valid. Input breakForce is { Infinity }.
UnityEngine.Joint2D:set_breakForce(Single)”

Why?!

1 Like

I’ll get this passed onto the docs team. Not totally sure this is an obvious issue. (At least to me!)

1 Like

It’s been over 5 weeks now. Any news what the status is?

I have no clue what I should do about the error message.

Peter

Any update on this? I’m having the same problem. How can we set the breakforce to Infinity if not via Mathf.Infinity? Even if I copy the current value (which is correctly set to Infinity in the Inspector) and then set it later back to that later in the code I get the same error, eg I cannot set it to a value it had previously.

1 Like

This is still not solved apparently. Getting the same error about assign attempt not being valid. Does anyone know a working way (in C#) to set joint break force and torque to infinity?

1 Like

same error. any update? setting the break force to really really high will probably be just fine for my purposes tho.

1 Like

Any updated on this??? Still not working in 2017.4.

Please Do Something I am Facing the same problem

to fix it i have to use a huge float number. which doesn’t look good to me.