Minecraft mod Mammoth will allow servers to host thousands of players without keeling over

Thousands of Steves piled atop one another in Minecraft.
(Image credit: Mojang)

It's Monday on PC Gamer and we haven't had any hot server chat yet: but fear not! An upcoming Minecraft mod of serious ambition is about to change all that, and may even have a wider impact on the platform's future. Essentially, it comes down to one problem: Minecraft-as-is processes all information about a server on a single CPU (single-threaded). So you could have the biggest and beefiest PC in the world but, as soon as it's having to deal with multiple dozens or even hundreds of players, you're going to get a huge performance hit, the server's tick rate will decrease to the point it's unplayable, and no-one's having fun.

The 'world record' for concurrent Minecraft players in a single world is 2622, a messy accomplishment where none of those players was able to actually do anything but, hey, they were there. This just wasn't good enough for coder Jackson Roberts, who at the beginning of 2020 wanted a lockdown project, and decided to create a gigantic Minecraft server that could host thousands of players without lag. Minecraft's existing single-threaded server software clearly wasn't up to the job so Roberts and collaborator Harvey298 decided they would work out how to build their own, calling the project Mammoth.

The first attempt, as Roberts explains, was a proof-of-concept system that chopped up a Minecraft world into 1024 blocks which were each run by their own server: the border areas synchronised and servers transferred moving objects between one another. However, it had too many issues: players couldn't see each other 'across' servers, one server going down rendered that portion of the world inaccessible, and fundamentally the solution didn't solve anything if lots of players congregated in a small area.

After this experience Roberts set a bunch of goals for Mammoth, including: Players must be able to see each other, even if on different server processes; When a player places a block or updates a sign, it should be immediately visible to all other players; If one server is down, the entire world should still be accessible; If needed, servers can be added or removed at-will to adapt to the amount of players.

The idea that he came up with was a centralised, backend database that could communicate between Minecraft servers as they popped in and out of existence, and continually pass messages about, for example, player movements. After trying some existing software such as redis and SpatialOS Roberts found it unfit for his purposes and, as you do, decided to build his own software, WorldQL, which he describes as "a real-time, scriptable spatial database built for multiplayer games [which] can replace traditional game servers or be used to load balance existing ones."

So: the new version of Mammoth, which is due to release on September 8, is built on World QL which stores "all permanent world changes and pass[es] real-time player information (such as location) between servers." Basically, each server is constantly reporting its data to World QL, which is then asking questions of other servers based on these reports: if it knows one player is near another, and the first player's server says they've moved, WorldQL asks what the other one is doing.

"In Mammoth, no single Minecraft server is responsible for storing the world. All block changes from the base seed are centrally stored in WorldQL. These changes are indexed by chunk coordinate and time, so a Minecraft server can request only the updates it needs since it last synced a chunk."

Jackson's post goes into more detail on exciting aspects like "real-time block synchronisation", message brokers and the future potential for Minecraft mini-games created in World QL's scripting environment (because, by default, they'll be able to take advantage of the player scaling.) Here is Mammoth's github page.

The debut of Mammoth will be of particular interest to some of Minecraft's more unusual communities, such as those that like playing on anarchy servers, as well as enabling a whole host of other large-scale activities that previously just weren't possible. Expect to see this being tested out on servers like 2b2t and, if it works as claimed without falling over, quickly becoming part of the scenery. As you can see in our list of the best Minecraft servers, people never stop coming up with weird and wonderful ways to play and, if Mammoth can deliver on the talk, its impact may well live up to the name.

Image

Minecraft potions: Recipes and brewing guide
Minecraft enchantments: Magical reference list
Minecraft villagers: All the jobs and trades
Minecraft realms: How to start your own server

Rich Stanton

Rich is a games journalist with 15 years' experience, beginning his career on Edge magazine before working for a wide range of outlets, including Ars Technica, Eurogamer, GamesRadar+, Gamespot, the Guardian, IGN, the New Statesman, Polygon, and Vice. He was the editor of Kotaku UK, the UK arm of Kotaku, for three years before joining PC Gamer. He is the author of a Brief History of Video Games, a full history of the medium, which the Midwest Book Review described as "[a] must-read for serious minded game historians and curious video game connoisseurs alike."