Tire pop question - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Tire pop question (
/showthread.php?tid=222568)
Tire pop question -
Haris Hadzic - 07.02.2011
Can someone help me to make some code which checks is the tire poped

Actually I should use this: GetVehicleDamageStatus(vehicleid,panels,doors,ligh ts,tires);
but I dont know what to do next :S this just checks vehicle parts and where is a part who done something if some of these vehicle parts are damaged??
I mean if my tire is poped then I would add some actions... If you dont get it I'll write some bugged code which doesnt exist:
if(tire1poped)
{
repairtire1;
}
Re: Tire pop question -
JaTochNietDan - 07.02.2011
https://sampwiki.blast.hk/wiki/GetVehicleDamageStatus
The function stores information about each part of the vehicle in a variable, then you can use the variables to do the check you need, for example:
pawn Код:
new panels,doors,lights,tires;
GetVehicleDamageStatus(vehicleid,panels,doors,lights,tires);
if(tires > 0) // At least one tire is popped
If you want to know the tire states, see
TireStates on the SA-MP Wiki.