I am currently developing an application in Python that has a match making functionality to form sports teams of 4 and group them by skill. The following has been implemented and works.
- Form full matches of four level 5 players until there are non left
- If there are some left, form a match with the remaining level 5 players and some level 4 players.
- continue like this until all players have been put into a match and put potentially remaining players onto a waitlist
Now, the objective is to allow users to specify at signup if they want to play with a specific other player. This of course can cause chains of relationships. The choice does not have to be mutual to come into effect. These indications should overrule the skill matching.
I am struggling really hard to come up with solutions. Is there preferred existing algorithms that can solve for this? I was looking at assigning cost (Hungarian algorithm) etc. but that fairly extensively ruined my already working skill match making.
I am grateful for pointers in the right direction or any ideas, really.