This is the server and client that uses my NetSnake system
This system is supposed to be a generalised protocol for command line multiplayer games.
✅Protocol Rewrite
⚒️Server list system / UI
⚒️Beta release
❌Clean up client
✅Some way to prevent players from eating all apples on the map
❌Tic-tac-toe
❌Session system
❌Cookie system Module System
❌Redirect system
❌UI system
❌Leaderboard
❌Websocket to NetSnake translator and JS web client
The idea behind the module system is to allow more generalization. Games will implement specific functionality through their own modules.
For example: A game could provide sound effects though an optional sound module, a client without the sound module would simply have no sound.
On the other hand, servers could rely on certain modules, for example a game that would use a special module for rendering 3d graphics.
Modules would be negotiated at the start of a game session, where the server the server presents the modules it would like loaded, the client presents which of those modules it can load and then the server either tells the client to load the modules or does something else like: kicking the user or displaying an error message.
All current functionality will be rewritten into the following 3 built in modules:
- LetterInput
- ConsoleRendering
- 2dTextGraphics
In the future developers may choose to create their own modules.
Q: Why is it all a single file
A: At the time, this project started out as a very simple single file python script that displayed a bouncing DVD logo.
I then reused the rendering system for a Tetris game and then later snake. (since it was still very basic, I didn't want to bother with virtual environments)
After making the snake game, I kept improving it by increasing the map size (which required rewriting most of the game),
eventually I rewrote the snake to be a class allowing support for multiple snakes, and at that point I decided to make it fully multiplayer.
After making, it multiplayer, I realized that the system is decently generalized and would allow for other command line multiplayer games, and that's where we are now.
Q: Will there be snake personalization or cosmetics
A: We're limited to the UTF-8 characterset so no, I might add an ability to make your snake fat as an easter egg though