SA-MP Forums Archive
[FilterScript] Car Color Changer(Random, zcmd) - 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: Filterscripts (https://sampforum.blast.hk/forumdisplay.php?fid=17)
+--- Thread: [FilterScript] Car Color Changer(Random, zcmd) (/showthread.php?tid=549463)



Car Color Changer(Random, zcmd) - BackScreen - 06.12.2014

Hey, this is a car color changer(random) by me.(BackScreen).

Enjoy!

PHP Code:
#include a_samp
#include zcmd
#define function%0(%1)  forward%0(%1);public%0(%1)
new boolplayerChangeColor[MAX_PLAYERS char];
CMD:carcolor(playeridparams[]) {
    if(!
IsPlayerInAnyVehicle(playerid))return SendClientMessage(playerid, -1"You need to be in a vehicle to use this command");
    
SetTimerEx("changeColor"1000true"i"playerid);
    
playerChangeColor{playerid} = true;
    return 
SendClientMessage(playerid, -1"Enjoy your car color changer ;)");
}
CMD:carcoloroff(playeridparams[]) {
    if(!
playerChangeColor{playerid})return SendClientMessage(playerid, -1"Car color is already off");
    
KillTimer(playerid);
    
playerChangeColor{playerid} = false;
    return 
SendClientMessage(playerid, -1"Your car color changer is turned off.");
}
public 
OnPlayerDisconnect(playeridreason)return playerChangeColor{playerid} = false;
function 
changeColor(playerid)return ChangeVehicleColor(GetPlayerVehicleID(playerid), random(255), random(255)); 
Pastebin: http://pastebin.com/bC6MqZmF


Re: Car Color Changer(Random, zcmd) - Alex Magaсa - 07.12.2014

Simple


Re: Car Color Changer(Random, zcmd) - $Bayside$ - 07.12.2014

Nice work.. try putting it in pastebin.


Re: Car Color Changer(Random, zcmd) - BackScreen - 07.12.2014

Quote:
Originally Posted by $Bayside$
View Post
Nice work.. try putting it in pastebin.
the pastebin link is under the code..


Re: Car Color Changer(Random, zcmd) - StephenBrash - 07.12.2014

Not bad, it's nice and simple.


Re: Car Color Changer(Random, zcmd) - BackScreen - 07.12.2014

Quote:
Originally Posted by StephenBras
View Post
Not bad, it's nice and simple.
thanks =]


Re: Car Color Changer(Random, zcmd) - M0HAMMAD - 07.12.2014

simple but nice .


Re: Car Color Changer(Random, zcmd) - BackScreen - 07.12.2014

Quote:
Originally Posted by M0HAMMAD
View Post
simple but nice .
thx.


Re: Car Color Changer(Random, zcmd) - Jakwob - 07.12.2014

nice god job +rep


AW: Car Color Changer(Random, zcmd) - Flori - 07.12.2014

Cool.