here´s the script so far :) just add it on the character controller and put the bullet in the variable :)
var Char_Bullet : Transform;
function Update () { if(Input.GetButtonDown("Fire1")) { var bullet = Instantiate(Char_Bullet,GameObject.Find("Gun_Spawn").transform.position,Quaternion.identity); bullet.rigidbody.AddForce(transform.forward * 2000); }
}
MinecraftJobs 2 months ago
At 0:25 when i double click, nothing pops up, rendering me unable to change/modify/add any script/s. Any help? :\
superdvdman 3 months ago
Is this a full step by step game tutorial in c#?
jordannw2010 4 months ago
i have your script, but the bullet doesn't go forward. it transform to the left. So i change "..transform.forward.".. to..".. transform.right.." and the bullet goes forward. Please help me!! I use unity 3.3 pro.
Chimaerafish 10 months ago
Comment removed
dranoel1963 1 year ago
thnks!!
SaigoMember 2 years ago 4
here´s the script so far :) just add it on the character controller and put the bullet in the variable :)
var Char_Bullet : Transform;
function Update () { if(Input.GetButtonDown("Fire1")) { var bullet = Instantiate(Char_Bullet,GameObject.Find("Gun_Spawn").transform.position,Quaternion.identity); bullet.rigidbody.AddForce(transform.forward * 2000); }
}
MinecraftJobs 2 months ago
At 0:25 when i double click, nothing pops up, rendering me unable to change/modify/add any script/s. Any help? :\
superdvdman 3 months ago
Is this a full step by step game tutorial in c#?
jordannw2010 4 months ago
i have your script, but the bullet doesn't go forward. it transform to the left. So i change "..transform.forward.".. to..".. transform.right.." and the bullet goes forward. Please help me!! I use unity 3.3 pro.
Chimaerafish 10 months ago
Comment removed
dranoel1963 1 year ago
thnks!!
SaigoMember 2 years ago 4