加速装置を作ろう:Rigidbody.AddForce

オブジェクトを加速させる
using UnityEngine;
using System.Collections;
public class AccelPoint : MonoBehaviour {
void OnTriggerEnter(Collider other){
other.gameObject.GetComponent<Rigidbody>().AddForce(new Vector3(0,10,30), ForceMode.VelocityChange);
}
}













【旧版】BallGame(全25回)
他のコースを見る