WheelCollider.suspensionDistance 悬挂距离

var suspensionDistance : float

Description描述

Maximum extension distance of wheel suspension, measured in local space.

车轮悬挂的最大延长距离,基于自身坐标空间。

Suspension always extends downwards the local y-axis. Suspension travel will be scaled by the transform's scale.

悬挂总是在y轴延长向下。如果变换的缩放被改变,悬挂运动也将被缩放。

using UnityEngine;
using System.Collections;

public class example : MonoBehaviour {
	public void Awake() {
		collider.suspensionDistance = 0.1F;
	}
}
collider.suspensionDistance = 0.1;
Page last updated: 2010-12-22