Why Lullwood, an AI-built browser game, is built in three.js

Lullwood, our free browser horror game, is built in three.js because the agents that build it work on text. Almost everything the game is sits in source files an agent can open, search and diff, and the one 3D model it loads is 226 KB. We never built Lullwood in another engine, so this is a reason, not a comparison.

On 2026-11-04 a Bluesky post by Axy Lusion linked an X post by Lucca Cerf about giving Three.js, Godot, Unity and Unreal almost the same prompt, one engine after another, over four days. The Bluesky post sums it up: “Three.js and Unity won because agents can read the files as text. Unreal’s binary assets shut them out.” That is their experiment and their conclusion. We have not reproduced it, and we read only those two short posts, not the full thread. What we can do is count how much of our own project an agent can read as text.

What the repository holds

We ran git diff --numstat from the empty tree to origin/release/next at commit 0698b3f on 2026-11-12. For a file git treats as binary it prints a dash instead of line counts, so it sorts the repository without our opinion in it.

  • 793 tracked files: 746 text, 47 binary.
  • The 47 binary files: 42 PNG, 2 WebM, 1 MP4, 1 ICO and 1 GLB. Thirty of the PNGs are country flags (56,449 bytes in all). Nine more are home-page screenshots, press images and a controls diagram. The other eight are two social-card images, the apple touch icon, two QA recordings, the favicon, death.mp4 (60,635 bytes) and the GLB.
  • One model: public/models/letter-balloons.glb, 226,360 bytes. We searched for .glb, .gltf, .fbx, .blend, .psd, .unity and .uasset files, and that is the only hit. There are no scene files or project files of any kind.
  • The checks are text too: 177 Playwright spec files in e2e/ and 87 unit-test files.

By bytes the picture flips: 29,947,013 binary against 7,556,412 text, because nine marketing PNGs in public/ weigh 25,699,407 bytes between them. The game does not request those, as our post on what the game ships found. So we are claiming a narrow thing: the game’s behaviour, its tuning, its sound and its tests are text. The repository also holds a lot of pictures, and we are not hiding them.

The one file an agent cannot read

A .glb is a 12-byte header, then chunks. This one has a 20,116-byte JSON chunk and a 206,216-byte binary chunk. The JSON is readable: we read it with a short script and found 26 meshes, 26 nodes, 78 accessors and one material. The binary chunk is vertex data, and a diff of it is not something a reviewer can read.

The code is built so the game does not depend on it. engine/forest-engine.js loads the file with GLTFLoader at L566, and the error callback ends in a comment, keep the canvas fallback, so if the model fails to load the leaderboard name is drawn on a canvas instead. The model is third-party, credited on the Lullwood credits page.

What reading it as text did, once

On 2026-10-11 we changed the default difficulty from Night to Blackout. That is PR #1066, squashed as commit 10a1851: 10 files, 35 insertions, 15 deletions. The behaviour change is three one-line edits to a string literal, 'night' to 'blackout': the engine’s let difficulty, the engine’s hudState object, and INITIAL_HUD_STATE in components/Hud.tsx. The rest is labels, comments and test assertions that assumed the old default.

The author changed two of the three. The Code Reviewer agent returned CHANGES REQUESTED naming the third, the hudState literal at line 4670 of that commit, and the commit message records the effect: a first-time player’s shop would have shown Night pricing (120 embers) while charging Blackout pricing (140). We did not re-run that bug, so that figure is the commit message’s. It was fixed with one line. A default that lives as a literal in three places is something a search finds and a diff shows, and that is the whole mechanism we can point to.

What this does not show

  • No comparison. We built Lullwood once, in three.js and Next.js. We have no timing, no pass rate and no cost figure for any other engine, and we did not try an engine editor, so we cannot say what we gave up.
  • Readable is not tidy. The game engine we wrote on top of three.js is a single file, engine/forest-engine.js, 9,691 lines and 595,103 bytes. Our devlog posts cite it by line number.
  • Text is not correctness. The review above caught a miss; it also shows the miss happened.
  • Other people’s games. Simon Willison’s October 28 write-up says all four games he describes are HTML and JavaScript running in the browser. He writes that he vibe coded them without looking at the code at all. In Lullwood another agent reads the code.

Where to go next

The byte-level count of what the game loads is in a night forest with one model file, and who does what between the founder and the agents is in who makes Lullwood. Play Lullwood free in the browser and judge the result from inside the forest.