At the moment I have a script that is firing a sphere, when i press the button which makes it fire; the pellet comes out but does not move across the screen, it just stays in a stationary position. whereas I would like it to move across the screen forward...
Script:
#pragma strict
public var pellet : Transform;
function Start () {
}
function Update () {
if (Input.GetKeyUp("o"))
{
var pelletfire = Instantiate (pellet, gameObject.Find("pellet_Spawn").transform.position, Quaternion.identity);
pelletfire.rigidbody.AddForce(transform.forward * 500);
}
}
Thanks for any suggesitons