Wanted color. How can this possibly be wrong? xP
#2

Quote:
Originally Posted by bartje01
Посмотреть сообщение
Hey guys. I have a public that has to set your color to your team color.
But it must set it to darkred if you are a suspect.

Now if you are a grove member it perfectly sets your color to green or to darkred if you are a suspect.
But when I'm not in any faction my name is white. And when I want to make him suspect then, his name flashes from white to darkred but it has to stay on darkred till the wantedlevel is gone.

please help

pawn Код:
public teamcolor(playerid)
{
if(GetPlayerWantedLevel(playerid) >=1)
{
SetPlayerColor(playerid,COLOR_DARKRED);
return 1;
}
if(cop[playerid] >=1) SetPlayerColor(playerid,COLOR_BLUE);
else
if(grove[playerid] >=1) SetPlayerColor(playerid,COLOR_GREEN);
else
if(civ[playerid] >=1) SetPlayerColor(playerid,COLOR_WHITE);

return 1;
}
Try:
pawn Код:
public teamcolor(playerid)
{
if(GetPlayerWantedLevel(playerid) >=1)
{
SetPlayerColor(playerid,COLOR_DARKRED);
return 1;
}
else
{
if(cop[playerid] >=1) SetPlayerColor(playerid,COLOR_BLUE);
else
if(grove[playerid] >=1) SetPlayerColor(playerid,COLOR_GREEN);
else
if(civ[playerid] >=1) SetPlayerColor(playerid,COLOR_WHITE);
}

return 1;
}
Reply


Messages In This Thread
Wanted color. How can this possibly be wrong? xP - by bartje01 - 23.01.2011, 10:59
Re: Wanted color. How can this possibly be wrong? xP - by DeathOnaStick - 23.01.2011, 11:39
Re: Wanted color. How can this possibly be wrong? xP - by bartje01 - 23.01.2011, 11:44
Re: Wanted color. How can this possibly be wrong? xP - by DeathOnaStick - 23.01.2011, 11:44
Re: Wanted color. How can this possibly be wrong? xP - by bartje01 - 23.01.2011, 11:46
Re: Wanted color. How can this possibly be wrong? xP - by bartje01 - 23.01.2011, 12:57

Forum Jump:


Users browsing this thread: 2 Guest(s)