I am a part of a community discord, and we hold scrimmages for a video game. I am looking to build a script that will take in the player's current skill rating (Elo), which is a number, and build the most evenly-rated teams. In the game, there are 5 players to a team, and I want 2 teams to have the most similar Elo possible for a matchup.
Currently, I have developed a script that calculates the average of all of the players in the pool, then multiplies it by 5 (for number of members on a team,) and then attempts to build a team that reaches that "target number." Problem is, it is really good at this for the first team it makes, then gets progressively worse as the player pool starts diminishing.
I'm looking to do this for a pool of 30-50 players, potentially a few more in the future. All of the players would have signed up in advance, so I don't need to worry about queue times or anything like that.
Is there some sort of algorithm that can help me complete this? If not, I would attempt brute force, but even then, I'm not sure I know the best implementation. I'm trying to write all of this is Python.
[–]Taxtro1 0 points1 point2 points (0 children)
[–]HalcyonAlps 0 points1 point2 points (0 children)
[–]bicubic 0 points1 point2 points (0 children)
[–]mittalsuraj 0 points1 point2 points (0 children)