OnVehicleDeath Problem..
#1

ok.. so, i give a player a vehicle, and i code itl ike this

Code:
onplayerspawn 

car[playerid] =  CreateVehicle(444, -25.4514,462.4341,31.8625,19.7708, 6, 54, -1);
PutPlayerInVehicle(playerid,car[playerid],0);
this works fine, but now i want to know when the vehicle dies.. so i do this

Code:
 onvehicledeath
for (new i = 0; i != MAX_PLAYERS; i++)
{
if (car[i] == vehicleid)
{ 
SendClientMessageToAll(TRES,"A vehicle has died");
car[i]=-1;
}
}
but it seems to work only when your vehicle goins in the water, not when it actualy blows up.. you know its health goes lover than 250, and it blows up.. so what is the problem?
Reply


Messages In This Thread
OnVehicleDeath Problem.. - by MrIncredible - 05.02.2011, 18:58
Re: OnVehicleDeath Problem.. - by MrIncredible - 05.02.2011, 19:21
Re: OnVehicleDeath Problem.. - by MrIncredible - 05.02.2011, 22:13
Re: OnVehicleDeath Problem.. - by marinov - 05.02.2011, 22:15
Re: OnVehicleDeath Problem.. - by MrIncredible - 07.02.2011, 00:14
Re: OnVehicleDeath Problem.. - by MrIncredible - 08.02.2011, 22:02
Re: OnVehicleDeath Problem.. - by Unknown123 - 08.02.2011, 22:35

Forum Jump:


Users browsing this thread: 3 Guest(s)