09.11.2014, 00:20
Just because I'm awful at finding small errors, can anyone tell me what's wrong with the following code..
I don't get any errors or anything but the purpose of the code is failing. It's supposed to show players in the radar only if they're in the same team.
Thanks in advance.
pawn Код:
new pTeam = GetPlayerTeam(playerid);
foreach(Player, i)
{
if(GetPlayerTeam(i) != pTeam)
{
SetPlayerMarkerForPlayer(playerid, i, (GetPlayerColor(i) & 0xFFFFFF00));
SetPlayerMarkerForPlayer(i, playerid, (GetPlayerColor(playerid) & 0xFFFFFF00));
}
else
{
SetPlayerMarkerForPlayer(playerid, i, GetPlayerColor(playerid));
SetPlayerMarkerForPlayer(i, playerid, GetPlayerColor(i));
}
}
Thanks in advance.