WheelHit 车轮碰撞

Struct

Contact information for the wheel, reported by WheelCollider.

WheelCollider报告的车轮的接触信息。

Friction for the WheelCollider is computed separately from the rest of the physics, using a slip based tire friction model. This allows for more realistic behaviour, but makes wheel colliders ignore standard PhysicMaterial settings.

用于WheelCollider的摩擦力是独立于物理系统计算的,使用一个基于轮胎摩擦力模型的滑动。这样就可以有更加真实的行为,而且使车轮忽略标准的PhysicMaterial设置。

The way to simulate different ground materials is to query WheelCollider for its collision information (see WheelCollider.GetGroundHit). Usually you get the other collider the wheel is hitting, and modify wheel's forwardFriction and sidewaysFriction based on ground's material.

模拟不同地面材质的方法是查询WheelCollider获取它的碰撞信息(参考WheelCollider.GetGroundHit)。通常你可以获取车轮碰到的其他collider,并基于地面的material修改车轮的forwardFrictionsidewaysFriction

The other members of WheelHit structure are usually queried for information purposes or special effects. E.g. a "slipping tire" sound can be played if forwardSlip or sidewaysSlip exceed some threshold.

WheelHit结构的其他成员通常查询用于信息参考之用或特定效果。例如,如果forwardSlipsidewaysSlip,超过一定的阈值,播放一个轮胎刹滑动的声音。

参见:WheelCollider.GetGroundHit.

Variables变量

最后修改:2011年5月16日 Monday 21:16

本脚本参考基于Unity 3.4.1f5

英文部分版权属©Unity公司所有,中文部分© Unity圣典 版权所有,未经许可,严禁转载 。