SA-MP Forums Archive
Color Problem!! - 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: Color Problem!! (/showthread.php?tid=411650)



Color Problem!! - nor15 - 29.01.2013

I use this command when some one go on admin mode , but the color of the player isn't changed

PHP код:
dcmd_adon(playerid,params[])
{
    
#pragma unused params
    
new string[128];
    if(
InAdminMode[playerid] == 1)
    {
        
SendClientMessage(playerid,COLOR_ERROR,"You are already in admin mode.");
        return 
1;
    }
    if(
IsSpawned[playerid] != 1)
    {
        
SendClientMessage(playerid,COLOR_ERROR,"You must be alive and spawned in order to go into admin mode.");
        return 
1;
    }
    for(new 
w=0w<13w++)
    {
        
GetPlayerWeaponData(playerid,w,PlayerWeapon[playerid][w],PlayerAmmo[playerid][w]);
    }
    
SendClientMessage(playerid,COLOR_ADMIN,"You are now in admin mode.");
    
format(stringsizeof(string),"[ADMIN MODE]Administrator %s(%d) has gone to Admin Mode ,Don't shoot him. or be Warned.",PlayerName(playerid),playerid);
    
SendClientMessageToAll(COLOR_ADMIN,string);
    
InAdminMode[playerid] =1;
    
SetPlayerColor(playerid,COLOR_PINK);
    return 
1;




Re: Color Problem!! - ThePhenix - 29.01.2013

Are you sure "COLOR_PINK" is properly defined?


Re: Color Problem!! - Azn - 29.01.2013

Maybe you had a function to lock the color?
If so, remove that function, you don't need it.
SetPlayerColor itself is enough.


Re: Color Problem!! - nor15 - 29.01.2013

the COLOR_PINK is defined and everything is ok , i dunno what is the problem


Re: Color Problem!! - Azn - 29.01.2013

Something tells me that you didn't do what I told you to.