SA-MP Forums Archive
Vehicle Damage isn't loading. - 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: Vehicle Damage isn't loading. (/showthread.php?tid=410536)



Vehicle Damage isn't loading. - iGetty - 25.01.2013

I have in my script:

pawn Код:
mysql_fetch_field_row(data_value, "vPanels"); Vehicles[vCarID][vPanels] = strval(data_value);
mysql_fetch_field_row(data_value, "vDoors"); Vehicles[vCarID][vDoors] = strval(data_value);
mysql_fetch_field_row(data_value, "vLights"); Vehicles[vCarID][vLights] = strval(data_value);
mysql_fetch_field_row(data_value, "vTires"); Vehicles[vCarID][vTires] = strval(data_value);
           
UpdateVehicleDamageStatus(vCarID, Vehicles[vCarID][vPanels], Vehicles[vCarID][vDoors], Vehicles[vCarID][vLights], Vehicles[vCarID][vTires]);
But none of the places are shown as damaged? EG the doors aren't being damaged and things.

What do I need to do to set them to damage?

Thanks.


Re: Vehicle Damage isn't loading. - MP2 - 25.01.2013

printf() is your friend.


Re: Vehicle Damage isn't loading. - iGetty - 25.01.2013

Quote:
Originally Posted by MP2
Посмотреть сообщение
printf() is your friend.
I know that but...

Would you please be able to tell me the values of what these should be set to when I am updating them to the SQL?

Say, if I want to set in the SQL what the damage value should be, like:

new panel;

UpdateVehicleDamageStatus(vehicleid, panel...);

What would the value of "panel" be, to make it damaged?

Thanks!


Re: Vehicle Damage isn't loading. - MP2 - 25.01.2013

Binary or something. Not sure.

https://sampwiki.blast.hk/wiki/UpdateVehicleDamageStatus

Unfortunately the back doors aren't synced, so don't worry about those - they'll always be un-damaged.


Re: Vehicle Damage isn't loading. - iGetty - 25.01.2013

That'll do, thanks mate!