I tried making a bombing script, but in the proccess seem to have ruined my missile script. This
var missileSpeed : float = 10;
var missileBomb : Rigidbody;
function Update(){
if (Input.GetButtonDown ("Jump")){
var clone : Rigidbody;
missile = Instantiate(missileBomb, transform.position, transform.rotation);
missile.velocity = transform.TransformDirection (Vector3.forward * missileSpeed);
}
}
says: Assets/shooting/missile.js(6,9): BCE0049: Expression 'missile' cannot be assigned to. and: Assets/shooting/missile.js(7,17): BCE0019: 'velocity' is not a member of 'missile'.
It was working a second ago, but now it isn't. I deleted everything in the bombing scripts, as I altered this script to make it, but it didn't help.