JSON scenes, schema-checked
Plain, declarative files. A generated JSON Schema, llms.txt and AGENTS.md tell agents exactly what is allowed.
Scene reference →The game engine AI agents can actually use
Pebble3D is a browser 3D engine designed for LLMs: worlds are plain JSON scenes checked by a schema, and physics is deterministic Rust compiled to WebAssembly. Ask for a game and your agent interviews you first, then checks its work with headless screenshots.
Every field has a default and a description in the JSON Schema, so an agent can write a scene without reading engine code, and validate it before it runs.
Scene reference →{ "version": 1,
"environment": { "preset": "studio", "ground": {} },
"prefabs": { "ball": {
"mesh": { "primitive": "sphere" },
"body": { "restitution": 0.5 } } },
"entities": [
{ "id": "b1", "prefab": "ball",
"transform": { "position": [0, 4, 0] } } ] }
Plain, declarative files. A generated JSON Schema, llms.txt and AGENTS.md tell agents exactly what is allowed.
Scene reference →Rapier in Rust, compiled to WebAssembly. The same seed and inputs give a bit-identical result in the browser and in Node.
How it is checked →three.js WebGPU rendering with a WebGL fallback, and Gaussian-splat captures of real locations composited with your meshes.
Splat environments →One command renders any scene in headless Chromium and writes a PNG plus a JSON report of stats, console errors and the state hash.
pnpm shot →Measured in the shipped games, on the same engine you install.
Nine agent skills ship in the repo. A game request starts with
make-a-game, which runs them in order.
Ronin Outpost
Hold the gate against eight waves of the dead with a katana. Toon-shaded, with skinned zombie crowds.
animation · IK · toon style
Swarm Siege
Top-down tower defence against a glowing tide of thousands of instanced enemies, simulated in a worker.
instancing at scale · worker · picking
Breakpoint
Bring down towers built from 838 to 1,344 physics blocks, then watch your best shot re-simulated exactly.
rigid bodies · replay
Drift Drone
An FPV drone time trial through LED gates in a real 3D-scanned yard, against a re-simulated ghost.
force-driven flight · splats · depth of field
Ghostline
Marble time trials against a ghost that is re-simulated live from your inputs, not played back.
determinism · PBR
Skyrun
A parkour time trial across floating islands: ride ferries, lifts and a spinning wheel against your own ghost.
character controller · moving platforms
Field Notes
Photograph luminous anomalies inside two real, 3D-captured places, with a working depth of field.
Gaussian splats · depth of field
Ringout
Local multiplayer sumo for up to four on a collapsing, spinning arena, with a replay that proves itself.
impulses · kinematic movers · replay
Rockfall
Dodge escalating waves of falling rocks, with up to 1,800 live rigid bodies in the pit.
seeded spawners · scale
Lanternfall
A stealth heist in a keep generated fresh from a seed every run. Stay out of the lantern light.
scene generation · raycast AI
Chain Reaction
Contraption puzzles whose levels are JSON and whose solutions are verified headless in Node.
JSON levels · headless verify
Pebble Garden
A physics sandbox and level editor whose gardens export as scene JSON and import with readable errors.
scene JSON · validation · play and rewind
The repo ships the files coding agents look for, and every docs page has a plain-markdown twin. The engine and all 12 demos were built with AI coding agents.
git clone https://github.com/pebble3d/pebble3d
cd pebble3d
pnpm i && pnpm fetch-assets && pnpm dev
Needs Node 22.6 or newer and pnpm. No Rust: the physics WASM comes prebuilt. Getting started
Free for organizations under USD $50,000 a year in revenue plus funding. Players never need a license. License details