Version: 2019.2
public float breakForce ;

Description

Сила, которую надо применить к соединению, чтобы сломать его.

When a joint tries to constrain a Rigidbody2D it may need to apply a force to do so. This is known as the reactionForce. Each physics update, the breakForce is compared to the size of the reactionForce; if it exceeds it then OnJointBreak2D is called with a reference to the joint that broke. Knowing the joint that broke, you can check the actual reaction force that broke the joint using reactionForce or GetReactionForce.

The break force can be set to Mathf.Infinity to make the joint unbreakable by any amount of reaction force. You should use this if you never intend for the joint to break with force as it indicates that the joint should not be checked each physics update, therefore provides better overall performance.

See Also: reactionForce, GetReactionForce & OnJointBreak2D.

Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961