RSSy MYGO.pl Opublikowano Maj 25, 2019 o 07:26 RSSy Udostępnij Opublikowano Maj 25, 2019 o 07:26 Background/Credits I play on an AWP-only server, and frequently see that the scoreline ends up around 20-1 for one team. I looked for some plugins that involved scrambling teams, and while some do exist, the few that I've seen are relatively old. These aren't all that I've seen but the first ones I can find after searching.Admin Player Team Switch and Scramble Menu by r5053[CS:S/GO+DoD:S] Auto Team Scrambler 2 (Updated 27-12-2012 @ DODS/CSGO) by RedSword[ANY MOD] SwapTeam v1.2.6 (Updated 30/09/12) by bobbobaganCS:S Team Balance by dalto This doesn't have all of the features of the plugins I've shown above, but some of the things I've included were inspired by these and I'd like to include some of those features in the future.Description After a team wins a certain amount of rounds in a row, at the end of the round a pool of N of the top players on the winning team and N of the bottom players on the losing team are chosen and half of those two pools are swapped to the other team.ConVars (I'm not confident with how I've written these, I just looked at how the mapchooser plugin wrote ConVars and went off of that. So now I realize these ConVars are not supposed ) Spoiler PHP Code: sab_minstreak "5" //Amount of wins in a row a team needs before autobalance occurs"sab_scoretype "1" //If 0, use formula: score = Kills/Deaths+1. If 1, Kills/Deaths+Kills+1. If 2, Kills*Kills/Deaths+1."sab_displaychatmessages "1" //Whether to display chat messages if a balance occurs or not"sab_freezesurvivor "1" //Whether to freeze the person swapped if they are alive at round end. If false, they are killed"sab_lenientdecay "0" //If 1, subtract decayamount from a team's streak when they lose if their streak is greater than decayamount"sab_decayamount "2" //The amount to subtract from a streak if lenientDecay is true"sab_minplayersneeded "4" //The sum of players on both teams must be at least this number for a balance to occur"sab_amounttoswap "4" //The number of players on each team that will be swapped. This will instead use the number that is 1/8 of the maximum clients for your server if you set it to a number higher than what that would be" Installation Just drag and drop the .smx and you're good to go, the config will be auto-generated in ./csgo/cfg/sourcemod/SkillAutoBalance.cfgDependencies These are the #includes at the top of the .sp for this script, all besides one of which should already come with your sourcemod installation. <smlib> comes from here Spoiler Code: #include <sourcemod> #include <sdktools_functions> #include <sdkhooks> #include <cstrike> #include <smlib> Plans Although I don't intend to use this feature on my server, I do plan to add the ability for admins to manually swap individuals choose one player from each team to swap. Eventually.Note This is my first plugin/thread on this forum. Just wanted to share this and hopefully people can tell me how to improve this because I am not confident in my implementation. Thanks, and if you find this useful, enjoy. edit: Get Plugin doesn't work and I'm not sure how to make it work but I put the .smx in attached files as well. Attached Files Get Plugin or Get Source (skillautobalance.sp - 9.1 KB) skillautobalance.smx (19.2 KB) Wyświetl pełny artykuł Odnośnik do komentarza Udostępnij na innych stronach Więcej opcji udostępniania...
Rekomendowane odpowiedzi
Jeśli chcesz dodać odpowiedź, zaloguj się lub zarejestruj nowe konto
Jedynie zarejestrowani użytkownicy mogą komentować zawartość tej strony.
Zarejestruj nowe konto
Załóż nowe konto. To bardzo proste!
Zarejestruj sięZaloguj się
Posiadasz już konto? Zaloguj się poniżej.
Zaloguj się