Friendslop²: A Dungeon Crawler Made of Seeds, Shared Physics and AI Art
There’s a genre now that people call friendslop: cheap, messy co-op games whose real point is laughing with your friends. I’m making one, and since most of it was written by AI agents and the art drawn by AI, it’s friend slop and AI slop at once. Friendslop squared.
It’s a roguelite dungeon crawler for four or five players, first person, where every run is a new dungeon and everything in it is physics. You carry, throw and climb whatever you find, and proximity voice lets you hear your friends’ screams fade down the corridors.
This post is about how it works underneath: how the dungeon is generated, how physics stays in sync across five machines, and how the art gets made when you can’t model.
A dungeon from a seed
Nobody sends the dungeon over the network. Every player’s game builds it from the same seed, in three steps:
- The graph: which rooms exist and how they connect. A main path from the entrance to the exit, branches hanging off it, a loop or two, and locks on the connections.
- The layout: where each room and corridor sits on a grid, across up to three levels, with stairs, climbs and drops between them.
- The geometry: walls, floors, stairs and vaults, built stone by stone (more on that below), then torches, doors and furniture.
Each step has its own seeded random generator, and nothing in the game is allowed to call the global one. If any machine drew one extra random number, its dungeon would quietly drift from everyone else’s, so a test builds the same seed on several instances and compares a fingerprint of everything in it, down to the names of the nodes.
Here is seed 4242 as a graph:
And the same dungeon from above, coloured by height. The deep blue block is the chasm under the collapsing bridge, four levels down; the grey rooms past it are the rest room, the boss arena and the exit.
Locks live on edges
Rooms are places; the challenge is getting between them. So every barrier sits on a connection, never in a room: a winch-operated gate, a pit, a climb, a rope bridge, swinging blades, a collapsing corridor. Each is one of three kinds: an obstacle (it needs skill), a soft lock (it needs skill, or a key if you’re carrying something long or heavy), or a hard lock (nothing gets through without its key).
The generator only keeps a dungeon that its own solver can finish: it walks the graph, picks up keys, and checks that the exit is reachable. Then the physical tests check that a body can actually make every jump and climb, because a solvable graph with a gap one metre too wide is not solvable.
The rope bridge sags under weight, and if you lean too far it flips and dumps you into the dark.
Some corridors collapse behind you. The vault cracks, dust pours from it, and then the front comes, faster than you can walk.
The run ends with the finale: a way down three levels into a chasm, where some steps are missing. A loose pillar stands in each gap; you jump on, walk to the front, and ride it as it tips across. Once everyone has crossed, it falls into the abyss behind you.
For now, players are drawn as a blue stand-in mannequin.
A new kind of lock is a new file and a resource, not a change to the generator. The same goes for rooms: each room type and corridor type builds itself, so adding one never means editing the others.
Physics with five people
This was the hard part. A physics game for one player is simple: one simulation, one truth. With five players, each machine runs its own physics engine, and they disagree within a second.
The rule the whole game follows is short: whoever touches a prop simulates it.
- The host simulates everything by default: anything at rest, anything two people carry together, and all the enemies.
- When you pick something up alone, the host hands it to you, and your machine simulates it. Carrying, turning and swinging it then has zero lag for you, which is the only person who’d notice.
- Everyone else freezes their own copy and plays your stream back, a little in the past and smoothed, so it moves cleanly even on bad Wi-Fi.
- The host still decides what matters: who’s holding what, who owns what, and how much damage something did. Your machine reports a hit, and the host checks it’s plausible before anybody loses health.
Players are trusted with their own movement, and with the fights that involve them: whether your swing landed, whether you blocked in time. It’s co-op, so the game favours the player over strict fairness. Nobody is going to cheat their friends out of a fun evening; the danger is lag making a block feel broken.
A throw is an event, not a stream
Throwing is where streaming falls apart. By the time a thrown spear’s position reaches the other players, it’s already somewhere else. So a throw isn’t streamed: the thrower sends the launch (where, how fast, how it’s spinning, and when) and every machine flies its own copy of the spear from that moment. They come out the same because they start the same, and only the thrower’s copy decides what it hit.
A spear flies point first. Each copy turns itself every physics step so its point follows its own velocity, so it dips as it falls and comes out the same everywhere from the launch alone. It sticks in soft things, and it doesn’t check whose soft thing it is.
The thrower also claims whatever the spear is about to hit, so the crash is simulated on their machine, without waiting to ask the host.
Testing lag on one laptop
Tests that run several instances on one computer see almost no lag, which hides most of the bugs players will hit. So the game can fake it: a launch option holds back every incoming packet, and network tests can ask for 100 ms of it.
Walls and floors, stone by stone
The dungeon has no wall models. Every wall, floor, pillar, stair, vault and doorway is generated: code decides where each stone goes and cuts it, with courses that run level, joints that lean slightly so the wall looks hand-laid, bevelled edges, and arches built from wedge-shaped stones. The same code runs inside the Godot editor, so I can tweak a style and watch a wall rebuild.
How the stone looks is data, not code: a masonry style for how stones are laid, cut and coloured, plus styles for floors, columns, vaults, beams, stairs and doors. A new biome is mostly a new set of these.
It took a few attempts to get here. The same corridor, in the three looks the walls have had: grey blocks on a grid (still what the tests use), then stones cut by code in flat colours, then the same stones painted, with grime.
The vaults are where the stone kit shows off. The biggest hall in this seed is nine cells by eight and three storeys tall, roofed with rib vaults that spring from square piers, every stone placed by code.
Then the stones get painted. Instead of a texture per wall, there’s one trim sheet: a single painted image of strips, each a different kind of stone.
Every stone face takes a whole strip from the sheet, painted ends and rims included, placed in world space, so neighbouring stones never repeat the same patch. Wood works the same way from its own sheet.
On top goes grime: dirt along the bottom of every wall, damp hanging from the ceiling, patches at mid height, and moss. To know where the floor and ceiling of each space are, the level writes them into a small 3D texture, one pixel per grid cell. So a tall room’s walls only get dirt on the lowest storey, and the dirt line climbs with the stairs instead of floating over them.
The devices are built by the same kit: doors, gates, pedestals and torch brackets.
Blood, magic and secret doors
The gore is over the top on purpose. Every blow sprays from the point struck, a heavy blow sprays more, and a killing blow’s wound keeps gushing in pulses as the body falls, then leaves a pool. Drops that land splat on the floor and walls. What sprays (blood, ichor, bone chips, embers) is data on the creature, and how much is one number each player sets for themselves.
Magic is cast with a staff. You learn spells at shrines, each costs mana, and mana refills over time. A fireball flies where your crosshair points, bursts on what it hits, and hurts everyone in the blast, friends included, which in a friendslop game is a feature.
Some runs hide a secret room behind a wall that looks like every other wall. The Reveal spell sends a lilac wave over everything in front of you, and a hidden door caught in it shimmers open, runes and all. It works over the network like everything else: the cast goes off on your machine at once, the host confirms it, and the door opens for everyone.
AI-generated creatures and props
I can’t model, so the creatures and props go through a pipeline I built with AI. Hard objects and soft creatures take different routes.
Props: built from parts
For a prop like a torch or a winch, Gemini draws an orthographic reference (front, side and top views, flat and to scale) and a set of painted texture sheets: colour, plus normal and roughness maps. Then Claude Code builds the model in Blender through Blender’s MCP server:
- It measures the reference in pixels, zooming in on every detailed part (a joint, a cap, a bevel), because at full size the reference hides the shapes that matter.
- It builds the prop from a small kit of parts: anything round is a lathed profile (a shaft, a cup, a drum), the rest is prisms, blades and frames, all to real-world size.
- It checks that every part touches its neighbours, crops seamless tiles from the texture sheets, and renders the model next to the reference, over and over, until the proportions match.
- Everything is baked into a single texture and exported straight into the game.
Creatures
- Gemini draws a turnaround: front, side, back and top views of the creature, flat and to scale, like a model sheet.
- Claude Code models it in Blender from those views, through Blender’s MCP server: it measures the outlines in each view and builds the shape to match.
- Gemini paints the texture. Claude unwraps the model into a template, Gemini paints over it, and the painting goes back on the model with normal and roughness maps made from it.
- Rigging and animation, then export into the game.
Jointed creatures are different. The spider is built from segments, each pivoting at its joint, and the game walks it procedurally: feet planted, legs stepping in turn, each leg solved with inverse kinematics. So it walks over vaults and up walls without a single animation for it.
The skeletons are bone pieces from the same pipeline, attached to a standard humanoid rig, so they share its animations.
60 fps on a MacBook Air
All of this has to run at 60 frames per second on a MacBook Air M3, the laptop I make it on. That’s a harder target than it sounds, because the Air has no fan. Under heavy load its GPU slows as it heats up: about 20–25% slower after three minutes, and about 70% slower after twelve, and it only recovers after minutes of light work. With the display synced at 60 Hz, a frame that takes just over 16.7 ms doesn’t run at 59 fps; it drops to 30–45. So a scene with headroom on a cool machine falls off that cliff once it’s warm, and the rule is to budget for the warm laptop, not the cool one.
Measuring is its own problem. Godot’s Metal renderer on the Mac doesn’t report GPU time, so the performance tools run the game under Vulkan instead. It’s 20–25% slower there, but a change moves both by the same share, so it’s good for comparing. Because the laptop keeps slowing down as it warms, two runs one after the other can’t be compared either, so the tool measures a change against the original in alternating turns. It also has a mode that plays a real fight through the player’s eyes, and one that sweeps the level for its slowest spots.
What it found, in the biggest room during a fight:
- Shadows are about a quarter of the GPU’s time, and most of that is their soft edges: hard shadows alone save about 17%. How many lights cast shadows barely matters.
- The torch in your hand is about 12%, and the bounce light about 8%.
- Flickering flames, fire, wall decals and gore cost nothing measurable, once the gore was fixed.
The gore needed fixing. Every blood drop used to be lit per pixel by every light around it, and up close a single spray could fill the screen, so fights ran faster with blood switched off. Now each spray works out the light where it starts, once, on the CPU, and draws its drops with that: dark in a dark corridor, bright by a torch, and nearly free.
A few other things that earn their keep: the level builds occlusion boxes from its own walls, which halves what’s drawn for about 1 ms a frame; painting the stone costs about 1.8 ms in a stairwell (in rooms and corridors it’s lost in the noise), and the grime 10–15% of the GPU in rooms; and choosing a lower resolution renders the 3D at fewer pixels and upscales it, while the interface stays sharp.
How it got built
1,291 commits between 24 October and 18 November, about 87,000 lines of GDScript and 267 test files. As with my Serengeti project, Claude Code agents wrote most of it, working from a board of 22 epics and about 250 tickets kept as Markdown in the repo.
Two things made that work. First, written rules: the project’s guide lists the architecture rules (whoever touches a prop simulates it, every room type in its own file, seeded randomness only) and links to a document for each system, which every agent reads before changing it. Second, eyes: the game has 65 small tools that render screenshots or frame strips of one thing (a rope bridge, a gate, a wall’s grime) so an agent can check its work by looking instead of guessing. Every game screenshot in this post came from them.






















