About Team balance
#1

can some one help me to how i can create team balance i have this one:
Код:
public OnPlayerRequestSpawn(playerid)
{
  if(gTeam[playerid] == TEAM_CT && CTcount > TTcount)
	{
	  SendClientMessage(playerid,COLOR_RED,"[SERVER] Please choose another team so match will be balanced.");
	  return 0;
	}
	else if(gTeam[playerid] == TEAM_TT && TTcount > CTcount)
	{
	  SendClientMessage(playerid,COLOR_RED,"[SERVER] Please choose another team so match will be balanced.");
	  return 0;
	}
	return 1;
}
for OnPlayerDisconnect
Код:
if(gTeam[playerid] == TEAM_CT) CTcount --;
  else if(gTeam[playerid] == TEAM_TT) TTcount --;
can some one help me or give me other team balance, i got problem when someone loginto my server he can choose the team with 5players and the other one have 0.
Reply
#2

and this its on, OnPlayerSpawn
Код:
if(gTeam[playerid] == TEAM_CT)
	{
	  CTcount += 1;
  }
	else if(gTeam[playerid] == TEAM_TT)
	{
	  TTcount += 1;
	}
comon guys help me...
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)