SA-MP Forums Archive
GetVehicleHealth - 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: GetVehicleHealth (/showthread.php?tid=197212)



GetVehicleHealth - iRana - 08.12.2010

Hi guys Is there any way to change Float of GetVehicleHealth to int?? Thanks....


Re: GetVehicleHealth - iRana - 08.12.2010

Bump...;..............


Re: GetVehicleHealth - blackwave - 08.12.2010

Код:
new Float:health
GetVehicleHealth(vehicleid, health); Vehicleid = vehicle string or model ID



Re: GetVehicleHealth - Rachael - 08.12.2010

There is probably a better way than this, but I know this will work
pawn Код:
new string[8];
format(string,sizeof string,"%.0f",health);
new integer_health = strval(string);