28.08.2011, 22:51
Try this:
pawn Код:
forward SetColor(playerid);
public SetColor(playerid)
{
if(President[playerid] == 1)
{
SetPlayerColor(playerid,yellow);
}
if(IsPlayerXAdmin(playerid) && IsPlayerVIP(playerid))
{
SetPlayerColor(playerid,white);
}
if(Team[playerid] == TEAM_RED)
{
SetPlayerColor(playerid,RED);
}
if((President[playerid] == 1) && (IsPlayerXAdmin(playerid) || IsPlayerVIP(playerid)))
{
SetPlayerColor(playerid,yellow);
}
else
{
SetPlayerColor(playerid,BLUE);
}
}
SetColor(playerid); // OnPlayerSpawn