SA-MP Forums Archive
how chage color vehicle - 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: how chage color vehicle (/showthread.php?tid=474389)



how chage color vehicle - par30 - 07.11.2013

PHP код:
CreateVehicle(560, -1522.3668891.54726.8458, -3.7360, -1, -1100); 



Re: how chage color vehicle - NeMoK - 07.11.2013

CreateVehicle(modelid, Float, Float:y, Float:z, Float:angle, color1, color2, respawn_delay)

so..

pawn Код:
CreateVehicle(560, -1522.3668, 891.5472, 6.8458, -3.7360, COLOR1, COLOR2, 100);
of you want a command to change them..

pawn Код:
#define COLOR_ERROR 0x808080FF
#define SCM SendClientMessage

CMD:spray(playerid,params[])
{
new color1,color2;
if(sscanf(params,"dd",color1,color2)) return SCM(playerid,COLOR_ERROR,"Usage: /spray [color 1] [color 2]");
new vehicleid = GetPlayerVehicleID(playerid);
ChangeVehicleColor(vehicleid, color1,color2);
return 1;
}