SA-MP Forums Archive
OnVehicleTakeDamage? - 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)
+--- Thread: OnVehicleTakeDamage? (/showthread.php?tid=642271)



OnVehicleTakeDamage? - SeanDenZYR - 27.09.2017

Any function that does this?

if a vehicle take damage, cause i wanted to add this type of feature to my roleplay server: when a car takes "int" damage, their engine gets temporarily broken. So is there any default function for this? or is it a custom one? please answer me asap i need this.


Re: OnVehicleTakeDamage? - Zeth - 27.09.2017

I think you are talking about OnVehicleDamageStatusUpdate


Re: OnVehicleTakeDamage? - SeanDenZYR - 27.09.2017

i saw that, i just need help if this car get -40 damage, it will not be able to move for 5 minutes.


Re: OnVehicleTakeDamage? - Zeth - 27.09.2017

Then you can use GetVehicleHealth and get the vehicle health and once it reaches 40, freeze the player and set the timer to unfreeze for 5 minutes


Re: OnVehicleTakeDamage? - SeanDenZYR - 27.09.2017

no i meant if the car loses 40 damage at one crash, it will continue to the next codes