23.07.2009, 11:55
pawn Код:
public OnPlayerRequestSpawn(playerid)
{
new tcount[2];
for(new i, m = GetMaxPlayers(); i < m; i++)
if(IsPlayerConnected(i))
tcount[gTeam[i]]++; // <<<=================== THE ERROR LINE
if(tcount[gTeam[playerid]] > tcount[gTeam[playerid]?0:1])
return SendClientMessage(playerid, RED, "To balance the teams, please select the other team."), 0;
return 1;
}