返回介绍

RelativeJoint2D 2D相对关节

发布于 2019-12-18 15:38:25 字数 2734 浏览 1025 评论 0 收藏 0

class in UnityEngine/Inherits from: Joint2D

Description 描述

Keeps two Rigidbody2D at their relative orientations.

保持2个2D刚体在它们的相对方向。

Two Rigidbody2D connected together with this joint will have forces applied to them to keep them both at their relative linear and angular offsets. If the joint is not connected to another Rigidbody2D then the body with the joint will stay at its current linear and angular offset in world-space i.e. it will be anchored to the implicit static ground-body.

连接在一起的该关节的2个2D刚体将会应用力去保持它们的相对线性和角度偏移。

You control the maximum linear force applied to maintain the linearOffset by using maxForce.

你可以通过maxForce控制最大线性力来维持线性偏移量。

You control the maximum torque applied to maintain the angularOffset by using maxTorque

你可以通过maxTorque控制最大扭矩来维持角度偏移量。

Variables 变量

angularOffsetThe current angular offset between the Rigidbody2D that the joint connects.
当前关节连接的2D刚体之间的角度偏移量。
autoConfigureOffsetShould both the linearOffset and angularOffset be calculated automatically?
是否线性偏移量和角度偏移可以被自动计算出?
correctionScaleScales both the linear and angular forces used to correct the required relative orientation.
用于修正要求的相对方向的线性和角度力的比例。
linearOffsetThe current linear offset between the Rigidbody2D that the joint connects.
当前关节的两个刚体连接之间的线性偏移量。
maxForceThe maximum force that can be generated when trying to maintain the relative joint constraint.
当尝试维持相对关节方向时可以生成的最大力。
maxTorqueThe maximum torque that can be generated when trying to maintain the relative joint constraint.
当尝试去维持相对关节方向时可以生成的最大扭矩。
targetThe world-space position that is currently trying to be maintained.
关节不断尝试移动2D刚体到目标。该目标通过线性偏移量和角度偏移量定义。

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文