How to do class limit?
#5

try this
pawn Код:
// put this in the to of the script
new teamMembers[15];

// put this is OnGameModeInit
SetTimer("CheckTeams", 100, true);

// put this anywhere in the script
forward CheckTeams();
public CheckTeams()
{
  for(new i = 0; i < MAX_PLAYERS; i ++)
  {
    teamMembers[gTeam[i]] += 1;
  }
}

// then use this in your command
if(teamMembers[1] > 3) // the [1] is the team id
{
  // bla bla bla...
}
Reply


Messages In This Thread
How to do class limit? - by krawN - 26.07.2009, 16:56
Re: How to do class limit? - by James_Alex - 26.07.2009, 16:58
Re: How to do class limit? - by SpiderPork - 26.07.2009, 17:00
Re: How to do class limit? - by krawN - 26.07.2009, 17:05
Re: How to do class limit? - by James_Alex - 26.07.2009, 17:21
Re: How to do class limit? - by gtalover12 - 26.07.2009, 17:34
Re: How to do class limit? - by john11johng - 22.08.2009, 18:43
Re: How to do class limit? - by Mr_Finnigan - 22.08.2009, 18:45
Re: How to do class limit? - by john11johng - 22.08.2009, 20:07

Forum Jump:


Users browsing this thread: 1 Guest(s)