← All Workshops
MudEngine Part 7: Save & Load
Step 4 / 17
Create Players.toml and gitignore it
The second file holds the live side of the game: connected players and their rooms. This file is machine-generated — the server flushes it to disk on a timer (once a minute by default), exactly like an editor autosaving a document.
Because it is regenerated constantly, it must never land in version control. Add it to .gitignore right away.
Create the file:
mud-engine/Players.toml
# Live game state — flushed to disk by the server's autosave task (~every 60 s). # gitignored: this file is machine-generated, not part of the world. players = []
Ignore the live state file
echo "Players.toml" >> .gitignoreVerify it parses cleanly
taplo check Players.toml💡 Why two files?
The split mirrors how you treat the two halves of the game:
Game.tomlholds what the game is: rooms, exits, and later items and quest definitions. It is edited by hand, reviewed in pull requests, and versioned.Players.tomlholds what the game does: who is connected, where they stand, later their inventories and chat history. It is flushed on a timer by the server and would make every commit noisy — so it stays out of git.
Future parts keep adding to the live side (inventories, ground items, chat), never to Game.toml. Game.toml only grows when you design the world.
Step 4 / 17