You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fabian Eberts edited this page Aug 16, 2026
·
4 revisions
Adding a new game is easy. All you have to do is derive from a base class and override a handful of methods. The easiest way to add a game is to use the template (server/games/template.py), which is structured like a tutorial.
Here is a summary of the required steps:
Create a new module in server/games/
Implement a class derived from AbstractGame
Override the required methods
Add the new class to the list of games (server/games_list.py)
No API changes are needed when adding new games. It was designed to work with any game. The function to submit moves accepts keyword arguments (**kwargs). These are sent to the server and passed to the game class as a dictionary. The game state is also sent back as a dictionary. This allows for a maximum of flexibility.