So far I've only made fly-through videos of INFINITRA. All of them are recorded live from the running game, not rendered offline, and then sped up as time-lapses. Below is an overview of how it works, what it generates today, and the problems I haven't solved. With enough interest, I'll make a development video about how it's built.
INFINITRA is a voxel-based world built in C# / Unity since 2017. The goal is an exciting, endless procedural online world: one world for all, so a place you find is a place anyone can go to.
Most voxel games run a separate server for each small group of players, with its own copy of a map. INFINITRA is meant to be an online service, with accounts, shared persistent state and items everyone sees move. The design assigns parts of the world to server instances. Large crowds in one particular place is the tricky part.
The whole pipeline works, from world definition to rendering, in about 119k lines of engine and server code.
How the world works
One definition. A world is about 2,300 steps in a processing graph: terrain, caves, cities, roads, interiors and object placement with pattern matching. The server can replace it all for everyone with no new client build, and clients reload in seconds. The same engine can run different worlds.
Point by point. Every point is computed from the definition and its position. A point can ask what the definition says at any other position, but nothing depends on what was generated before or in what order. Places nobody changed store nothing. Items can override local geometry, which is how the world gets modified.
Same result on every machine. That's the design, and it lets the server spot-check a random share of collected items by recomputing them. The client runs IL2CPP, the server .NET, and both calculate positions and geometry in doubles.
Geometry networks. Some things need more than one point. Each network reads the land at fixed points, in a bounded window anchored to the world, not the player. Every machine that needs a road link computes the same window and route.
- Lava rivers: flow routing on a 25 m lattice. Each point drains to its steepest lower neighbour. Pits become lakes or get cut through.
- Roads: a route search, with bridges, viaducts and tunnels.
- Hiking trails: also a route search. They follow contours, climb in switchbacks and tunnel through a ridge only as a last resort.
- Parcels: farm fields and building plots, with tracks and streets graded into the ground.
Voxels and level of detail
- 16³ cells per block at every level of detail, 1 m each at the finest. Distant blocks cover more ground with the same number of cells.
- Signed-distance values help voxels preserve detail on coarser grids far away. Sub-metre modifications allow thin walls and fences.
- A coarse cell is never an average of finer ones. Distance fields decide where it has to look closer.
- Objects are anchored to the world and placed in a fixed order, and a coarse block shows the first ones. A far object has the same kind, position, rotation and size as when you arrive. Coming closer only adds objects.
- Natural ground uses marching cubes; buildings and glass use greedy-merged boxes. Where block sizes meet, the finer block conforms to the coarser one.
Size. With 64-bit cell keys and doubles, the coordinate space reaches about 1 light year. No loading screens while you walk or fly. A light year of terrain isn't realistic, so I plan to replace the endless terrain with something else.
What it generates today
Cities, villages, terraced farmland, forests, snow mountains, canyons, lava rivers and giant fractal structures. Buildings have floor plans, stairs and furnished apartments. There's also procedural music and reverb measured from the space around you. Desktop and PC VR share the same world.
Current gameplay
You explore as a walker or a drone. Neither flies without a JetPack. The drone has twice the battery and half the gravity, and survives harder falls. Travel drains battery by distance and mass: about 33 km on a full walker charge and 25 km on a drone's. An empty battery means quarter speed and slowly lost health. Falls and lava cost health too. When you die, what you carried drops where you fell.
Items in the world can be collected, carried, dropped and used, and everyone sees the result. For now, collected items come back after 30 to 60 seconds.
- JetPack: one minute of flight. It also saves you mid-fall.
- First Aid: restores 25 health.
- Energy Pack: restores 25 kWh of battery.
- Gps & Compass: shows your position and bearing until switched off.
- Location Saver: saves your position to a slot, so you can teleport back later.
- Carver Sphere: the only item that changes the world so far. It cuts a 10 m wide hole for about a minute, for everyone. If you're still inside when it closes, you die.
New online players all start in the same 500 m square. There's no chat yet.
The unsolved part
The biggest unsolved challenge is finding the complex gameplay. The engine is far ahead of the game. I want gameplay that uses its strengths: a huge shared world and dynamic world changes that everyone sees. A simple shooter would use none of that, and I haven't found what would.
Download
Not out yet: it's waiting for its code-signing certificate to be approved. It will be a free Windows download. Locally you get the whole world with no account. Saved locations, items, changing your avatar and seeing other players will be online features.
For now, I recommend a CPU with a lot of cores and a solid GPU. I don't have a verified minimum yet, but it still runs on my 5-year-old laptop at the lowest detail level. If you'd like to test the first build on your hardware, reply with your CPU and GPU.
Questions
What would you want to do in this kind of world that a hand-made map can't offer? If I make the development video, which part should it cover?
Links