Team Balancer - 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 Balancer (
/showthread.php?tid=83291)
Team Balancer -
will_92 - 24.06.2009
I made an TDM and sometimes , the team gets UNBALANCED , and i would like to know how could i make an team balancer, can anyone post an team balancer code for me please and thank you
Re: Team Balancer -
abhinavdabral - 24.06.2009
When did they get unbalanced ... when someone joins or when someone leaves?
Re: Team Balancer -
Burridge - 24.06.2009
Quote:
Originally Posted by ۞●•λвнiиаv•●۞
When did they get unbalanced ... when someone joins or when someone leaves?
|
I think he means he get's a lot of players, but loads choose one team and there's on a few in others. he's wanting somthign to make them balanced.
Re: Team Balancer -
abhinavdabral - 24.06.2009
OK ..so i guess he should then check the density of teams whenever someone disconnect or connect to the server .... and he should change the team of those who have the least score or the new who joined to the team having low players ..... change the teams until they got slightly balanced.
Re: Team Balancer -
will_92 - 24.06.2009
Yeh , but how would i do that
Re: Team Balancer -
abhinavdabral - 24.06.2009
well .. i need to see the code .... in which you have managed the Teams
Re: Team Balancer -
Marcel - 24.06.2009
When they are about to select a skin, ( OnPlayerRequestSkin ), check if the team related to that skin has less players then the other team, if so, tell him he has to select an other team. It's as easy as that, I did the thinking, now the only thing you have to do is work it out into code that SA:MP can run.
Re: Team Balancer -
abhinavdabral - 24.06.2009
Or might be you can directly check the teams at the class selection and then just Spawn him automatically by SpawnPlayer(playerid); to the team having less players ..