Destroy the vehicle on spawn of a new one?
#2

Quote:
Originally Posted by [mad
MLK (dino-host.com) ]
When you spawn a vehicle how would i make it destroy the old one because this looks alittle complex

http://mlk.pastebin.com/m718a53d5
If I read that right, all you have to do is at the top of the script do this:
pawn Code:
new SpawnedCar[MAX_PLAYERS];
Then when you make a new car do:
pawn Code:
SpawnedCar[playerid] = CreateVehicle(...);
Now the vehicle's ID should be stored there so you can do:
pawn Code:
DestoryVehicle(SpawnedCar[playerid]);
Reply


Messages In This Thread
Destroy the vehicle on spawn of a new one? - by [mad]MLK - 20.09.2009, 04:09
Re: Destroy the vehicle on spawn of a new one? - by lavamike - 20.09.2009, 05:10
Re: Destroy the vehicle on spawn of a new one? - by madman227 - 20.09.2009, 05:19
Re: Destroy the vehicle on spawn of a new one? - by FrostBytez - 12.10.2009, 13:05
Re: Destroy the vehicle on spawn of a new one? - by Donny_k - 12.10.2009, 13:15

Forum Jump:


Users browsing this thread: 1 Guest(s)