|
ok basically im using the line renderer. im trying to move it(and activate it) when i press a button so that it looks like a shot(this works). What i am asking is what do u need to, while holding a button i want to remove it and make it spawn back to its original starting position, after a period of time so it mimics shooting bullet paths like a machinegun. here is code:
thanks please just reply if u no the code and how to do this ive tried everyting so far and would appreciate the help. sorry if a question like this has been answered already.
(comments are locked)
|
|
First you should add these variables:
Then after that, deactivate the object and start the clock
This is untested and written in C# yeh ive figured it out i just made a new empty gameobject, and instantiated a prefab that has a lifetime so it will die, then i said if currenttime > timetospawn then instantiate new object :)
Jan 20 '11 at 08:01 PM
Samir 1
(comments are locked)
|
