imruiyeah / game_matchmaking Goto Github PK
View Code? Open in Web Editor NEWA game matching system written in java
A game matching system written in java
COMPILATION Please unzip the package and use maven and Java 8 to compile it. You can also use Intellij to open the project if you have Intellij installed. DESCRIPTION To solve the general matchmaking problem for online games, two steps are introduced: 1) Pick the first player in the queue, and find the similar players of him/her. This is handled by the PlayerFinder interface. I implemented two subclasses of PlayerFinder. 2) Split the players found in the above step into two teams and put them into a match. This is handled by the TeamBuilder interface. I also implemented two subclasses of TeamBuilder. All classes are fully covered by unit tests. A simple rating system is introduced to the each Player and it is based on the winning ratio. Most of the sorting of the players are based on their ratings. A simulator is also developed to simulate each of the match result and a console app is developed as a proof of concept. It is configured by Spring, we can use the Spring XML configuration file "matchmaking.xml" to achieve different combinations of strategies as well as their parameters. By using the simulator, back-testing can be conducted easily. In the future if new implementation of PlayerFinder and TeamBuilder interfaces are introduced, they can be added into the current framework seamlessly by just updating the XML configuration. FUTURE ENHANCEMENT The below enhancement can be done in the future to provide more robust matchmaking strategy: 1) Multi-threading can be supported by using reader/writer lock. 2) A more sophisticated simulator can be developed based on historical matching result. 3) Tune the configurations of each PlayerPicker and TeamBuilder to find the best parameters to fit the model. 4) Add retry and waiting logic in matchmaker to achieve better user experiences (i.e. players waiting longer should be matched more easily). 5) More robust rating methodology can be used, like the Glicko rating system: http://en.wikipedia.org/wiki/Glicko_rating_system.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.