Component
- animation
- audio
- BroadcastMessage
- camera
- collider
- CompareTag
- constantForce
- gameObject
- GetComponent.<T>
- GetComponentInChildren.<T>
- GetComponentInChildren
- GetComponents.<T>
- GetComponentsInChildren.<T>
- GetComponentsInChildren
- GetComponents
- GetComponent
- guiTexture
- guiText
- hingeJoint
- light
- networkView
- particleEmitter
- renderer
- rigidbody
- SendMessageUpwards
- SendMessage
- tag
- transform
Component.constantForce 恒力
var constantForce : ConstantForce
Description描述
The ConstantForce attached to this GameObject (null if there is none attached).
ConstantForce附加到GameObject(游戏物体)(如无附加则为空)。
using UnityEngine;
using System.Collections;
public class example : MonoBehaviour {
public void Awake() {
constantForce.relativeForce = new Vector3(0, 0, 1);
}
}
constantForce.relativeForce = Vector3(0, 0, 1);
最后修改:2010年12月11日 Saturday 2:26