A joint connects a Rigidbody to another Rigidbody or a fixed point in space. Joints apply forces that move rigid bodies, and joint limits restrict that movement. Joints give Rigidbodies the following degrees of freedom:
Unity’s provides the following joint components that apply different forces and limits to Rigidbody components, and give those bodies different motion:
属性: | 功能: |
---|---|
Character Joint | 模拟球窝关节,例如臀部或肩膀。沿所有线性自由度约束刚体移动,并实现所有角度自由度。连接到角色关节 (Character Joint) 的刚体围绕每个轴进行定向并从共享原点开始转动。 |
Configurable Joint | 模拟任何骨骼关节,例如布娃娃中的关节。您可以配置此关节以任何自由度驱动和限制刚体的移动。 |
Fixed Joint | 限制刚体的移动以跟随所连接到的刚体的移动。当您需要一些可以轻松相互分离的刚体,或者您想连接两个刚体的移动而无需在 Transform 层级视图中进行父级化时,这种关节很有用。 |
Hinge Joint | 在一个共享原点将一个刚体连接到另一个刚体或空间中的一个点,并允许刚体从该原点绕特定轴旋转。用于模拟门和手指关节。 |
Spring Joint | 使刚体彼此分开,但使刚体之间的距离略微拉伸。弹簧就像一块弹性物,试图将两个锚点一起拉到完全相同的位置。 |
2D 关节在名称中有 2D 字样,例如,Hinge Joint 2D(2D 铰链关节)。有关 2D 关节的摘要,请参阅 2D 关节文档。
关节还有其他可用于实现特定效果的选项。例如,可设置一个关节,确保在刚体施加到关节的力超过某个阈值时破坏关节。一些关节允许在连接的刚体之间产生__驱动力__以使它们自动运动。
注意:如果要在工业应用的上下文中构建运动链,例如模拟具有逼真物理行为的机械臂,应使用物理接合而不是这里描述的常规关节。
Did you find this page useful? Please give it a rating:
Thanks for rating this page!
What kind of problem would you like to report?
Thanks for letting us know! This page has been marked for review based on your feedback.
If you have time, you can provide more information to help us fix the problem faster.
Provide more information
You've told us this page needs code samples. If you'd like to help us further, you could provide a code sample, or tell us about what kind of code sample you'd like to see:
You've told us there are code samples on this page which don't work. If you know how to fix it, or have something better we could use instead, please let us know:
You've told us there is information missing from this page. Please tell us more about what's missing:
You've told us there is incorrect information on this page. If you know what we should change to make it correct, please tell us:
You've told us this page has unclear or confusing information. Please tell us more about what you found unclear or confusing, or let us know how we could make it clearer:
You've told us there is a spelling or grammar error on this page. Please tell us what's wrong:
You've told us this page has a problem. Please tell us more about what's wrong:
Thank you for helping to make the Unity documentation better!
Your feedback has been submitted as a ticket for our documentation team to review.
We are not able to reply to every ticket submitted.