Team Balance? - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Team Balance? (
/showthread.php?tid=274690)
Team Balance? -
0_o - 06.08.2011
How to Team Balance In A TDM Server? Like If Team 1 Has 25 Players And Team 2 Has 24 A Player Cannot Join Team 1. ?
Re: Team Balance? -
0_o - 06.08.2011
nyone Who Can Help?
Re: Team Balance? -
Kyle_Olsen - 06.08.2011
Would help if you posted part of your code...
Re: Team Balance? -
0_o - 06.08.2011
I Don't got a Code. I want A Code That Would Allow Team Balance In TDM Server.
Re: Team Balance? -
=WoR=Varth - 06.08.2011
https://sampforum.blast.hk/showthread.php?tid=224853
Next time use search button.
Re: Team Balance? -
dud - 06.08.2011
maybe this example will help you
Код:
new team1 = 6; // exm team 1 has 6 players
new team2 = 10; // exm team 2 heas 10 players
new timer;
public OnFilterScriptInit()
{
timer = SetTimer("balanceteams", 1000, 1);
return 1;
}
public OnFilterScriptExit()
{
return 1;
}
public balanceteams()
{
if (team1 > team2)
{
team2++;
team1--;
}
if (team1 < team2)
{
team2--;
team1++;
}
if(team1 == team2)
{
KillTimer(timer);
}
return 1;
}