View Full Version : Deathmatch Team Balancer
Deathmatch Team Balancer v1.0.0.4
Simple team balancer plugin for CS:S Deathmatch (mp_autoteambalance breaks in Deathmatch) :wink:
Server Console Vars:
dmtb_enable "1" // Enable the Deathmatch Team Balancer
dmtb_checktime "30.0" // How often to check if the teams are balanced - min = 30 (30 seconds) max = 600 (10 mins)
dmtb_playerlimit "2" // How uneven the teams can get before getting balanced - Min = 1 Max = 32
dmtb_adminsimmune "1" // Enable admins immunity from getting switched 1 = on / 0 = off
Install:
dmtb.smx -> addons\sourcemod\plugins
dmtb.sp -> addons\sourcemod\scripting
plugin.dmtb.cfg -> cfg\sourcemod
Version History:
v1.0.0.4
- Fixed a few bugs with GetUserAdmin
- Little less overhead on the code
v1.0.0.33
- Fixed any possible bugs with MaxClients & the reserved slots plugin
- Added checks to swap dead players first
v1.0.0.32
- Added an admin immunity option
v1.0.0.31
- Reverted the previous change
- Fixed a small bug with the max clients checking
v1.0.0.3
- Balance bug should finally be fixed - thanks to 1694 for the bug reports
v1.0.0.2
- Few more checks added to the code
v1.0.0.1
- Couple of internal code changes
Thanks to oxymoron for the main idea & all the diffrent code examples on the forums from various plugin authors :)
have fun dubbeh
lo,
your a yegod!!
Thanks for doing this, ill test it when im home!!
Cheers
xYx aka Oxymoron
could you post up the cfg cvars so i can read them in the forum plz?
I cant download at work
nps, posted up the cVar list
only thing i havn't got done yet is the auto assign option
I am very thankful for this plugin. I might have found a little bug though.
I have default settings. The server was 8 CTs v 6 Ts. The plugin noticed this and switched it to 6 CTs v 8 Ts.
I understand that i have dmtb_playerlimit "2" but should it not make it 7 v 7 or infact leave the teams as they were & not switch anyone?
Am I making any sense?
cheers
luv' u !!!!!!!!!!!!!!!!!!!!!!!!! After year of waiting for that, U DID IT ! lol thx !
nps :mrgreen:
xYx that bug should be fixed now :)
is this the most up to date version:
dmtb_1000.zip (13.0 KB, 1 views) ?
yeah, taken the plugin out of beta
Craftkiller
07-19-2007, 17:59
Any chance you could release the source code?
Any chance you could release the source code?
I believe the SourceMod license requires all plugins to make their source code available. It's in the download file.
Craftkiller
07-19-2007, 21:00
oh thank you, other ones have a seperate download link for source so I figured thats the only place itd be.
Sourcecode can be found in the "addons\sourcemod\scripting" folder
Think its illegal to release a plugin without the sourcecode under the GPL, unless u get special rights from the author
Seems that it doesn't wok for me ! 3 vs 1 and... nothing ever happen !? help ?
CSSDM 2.00 Final
Just out of curiosity what was the cvar dmtb_playerlimit set to?
dmtb_playerlimit 2 (default)
Tryed a few internal code changes
can you test this out & see if it works correctly now
thanks
currently trying... Will keep you informed.
EDIT : Seems to be working now ! thx !
EDIT2 : Worked only ONE time :s...
Added a few more checks to the code - hopefully that will fix the bug
Currently testing again...
EDIT : Erf, waiting a loooong time and still 4 vs 2...
the balance bug should finally be fixed now - might cause the teams might get swapped around a bit more
thanks for the bug reports :)
Currently Testing lol, feed back soon.
EDIT : Ah, become interesting. We were "1T vs 3CTs". Plugin detected that and swap... 2 persons -_-' so were were "3Ts vs 1CT". A least, plugin did something ^^.
thought that would happen xD
this version should 100% work, didn't check max clients correctly - can't see anything that would cause a problem
if your still having problems - try setting dmtb_playerlimit "1" & see if the bug still happens
Okay, testing now
EDIT : Okay, seems to be working this time ! At the begining i was afraid since one player was swapepd and swapped again evry 30 sec, but it appear that he was swapping team manually (he seemed to hate being CTs :p), at least I think it was that since it finally stoped...
thx for your quick answering, [add karma] (=> erf can't ^^)
FEATURE REQUEST :
Swap Immunity - admin immunity to swap
Admin immunity feature added in the latest version :)
Another suggestion : could the plugin swap dead player if possible ? I mean, I have cssdm_respawn_wait "3.50" sec, so it would be better if player were swap while dead (no suicide in stats). If you could add this variable :
dmtb_prefere_dead 1|0 // prefere dead player to swap, only active if cssdm_respawn_wait > 2 to avoid problem
Are something like that... don't know if that is possible.
cssdm_respawn_wait > "2" should not be "necessary" but much easy with that.
=========================
also, I never been swaped, so i was wondering if they were any obvious waring for the people who is swaped ? I mean more than the little "player xxxx joined the Cts forces" ? Because sometimes they seemes to not understand while they were swapped :p.
bye
topic is going down and down... so i up it expecting you, dubbeh, to see it :D
Only swapping dead clients can be done with the IsPlayerAlive & storing alive/dead players on each team then giving them swap priority
Adding the swap message will be really easy to add
I'll see what i can come up :) - having a little coding break atm
Okay cool. take your time.
up ! :p nothing new here ?
Been a little bit busy over the past few days with an AFK Manager ;)
Done a quick update to swap dead players first & fixed a couple of bugs with the reserved slots plugin
hello
I have find this in my sourcemod logs!!!
L 08/25/2007 - 19:49:36: [SM] Native "GetUserAdmin" reported: Client 1 is not connected
L 08/25/2007 - 19:49:36: [SM] Displaying call stack trace for plugin "dmtb.smx":
L 08/25/2007 - 19:49:36: [SM] [0] Line 174, /home/groups/alliedmodders/forums/files/2/9/2/1/8/19199.attach::TeamBalanceThread()
L 08/25/2007 - 19:49:41: [SM] Native "GetUserAdmin" reported: Client 1 is not connected
L 08/25/2007 - 19:49:41: [SM] Displaying call stack trace for plugin "dmtb.smx":
L 08/25/2007 - 19:49:41: [SM] [0] Line 174, /home/groups/alliedmodders/forums/files/2/9/2/1/8/19199.attach::TeamBalanceThread()
L 08/25/2007 - 19:49:46: [SM] Native "GetUserAdmin" reported: Client 1 is not connected
L 08/25/2007 - 19:49:46: [SM] Displaying call stack trace for plugin "dmtb.smx":
L 08/25/2007 - 19:49:46: [SM] [0] Line 174, /home/groups/alliedmodders/forums/files/2/9/2/1/8/19199.attach::TeamBalanceThread()
L 08/25/2007 - 19:49:51: [SM] Native "GetUserAdmin" reported: Client 1 is not connected
L 08/25/2007 - 19:49:51: [SM] Displaying call stack trace for plugin "dmtb.smx":
L 08/25/2007 - 19:49:51: [SM] [0] Line 174, /home/groups/alliedmodders/forums/files/2/9/2/1/8/19199.attach::TeamBalanceThread()
L 08/25/2007 - 20:01:56: [SM] Native "GetUserAdmin" reported: Client 1 is not connected
L 08/25/2007 - 20:01:56: [SM] Displaying call stack trace for plugin "dmtb.smx":
L 08/25/2007 - 20:01:56: [SM] [0] Line 174, /home/groups/alliedmodders/forums/files/2/9/2/1/8/19199.attach::TeamBalanceThread()
wfg JaY
Thanks for the bug report
Fixed this in v1.0.0.4 :)
tftpapst
01-26-2008, 02:20
Doesent work anymore. No Teambalance at any time
SM Version 1864
CSS DM 2.10
Linux
Doesent work anymore. No Teambalance at any time
SM Version 1864
CSS DM 2.10
Linux
confirming for Empires mod, not working, same SM version
Box Cutter
04-02-2008, 18:57
dubbeh, any plans to update this plugin, or is it dead? I would love to run but it sounds like it is no longer working?
DontWannaName
04-02-2008, 21:06
Needs to be moved to unapproved then. :(
Come on a littel bit update !!!!
works not anymore in game
dubbeh come on pls
Greetz
JaY
Box Cutter
05-22-2008, 15:36
Can anyone confirm if this is still working? Previous posts state it is not, but stats show servers are running it.
-BC
Gladiator69
06-11-2008, 08:01
Hello, does it works for Day of defeat source?
Nope ;)
Quick note to everyone trying this with other mods, this was only made to fix the mp_autoteambalance bug in CS:S with the rounds never ending. It's untested in other mods but a chance it will work
How do I download this? I cant see any download links (im new to this place so I am quite nooby).
Box Cutter
10-01-2008, 12:49
How do I download this? I cant see any download links (im new to this place so I am quite nooby).
http://forums.alliedmods.net/showpost.php?p=504735&postcount=1
Raptor10
03-11-2010, 13:21
Sry for a stupid question but I need an answer:
my server is setted as follow:
Sourcemod 1.2.4
Gungame5+Deathmatch (Eventescripts)
This nice plugin works anyway or needs GG+DM made for Sourcemod ?
thanks
geshev69
01-23-2011, 12:21
Does this plugin works for orangebox? Please someone to update it
Heartless 1.0
03-01-2011, 10:33
Does this plugin swap players on death?
Does this plugin swap players on death?
Yep.
What is the Admin flag to get imune? if there is one.
I have admin and members on my server, i want Members to get TeamBalance imune to, but they DONT have Basis Admin
Blacksilver
01-11-2013, 15:44
Player get switch will there are alive :D
CT with T model and CT with T model not really funny :o
if (!IsPlayerAlive (i) && !IsProtectedAdmin (i))
You have the check but ... i dont know ^^
Once I made similar plugin. If this one is not working, you can try my version. Requires colors from this post (https://forums.alliedmods.net/showpost.php?p=2051486&postcount=373)for compilation
vBulletin® v3.8.7, Copyright ©2000-2024, vBulletin Solutions, Inc.