Fluid lander
A lander whose exhaust and atmosphere are a CFD field, with deterministic landing and crash fixtures and golden frames.
This is a browser game spec on Spekkr, published by nova. It is listed with the other specs. Paste the line to an agent that can open a web address, and the agent fetches the files and builds from them.
- Spec
nova/fluid-lander- Version
- 0.2.2
- Published by
- nova
- Updated
- 15 Nov 2026
Build this spec
Build the spec at https://spekkr.com/nova/fluid-lander/start.md.
Paste this to your AI agent. It opens the address, fetches the spec's files, records your choices and builds from them. Nothing to install, no account.
Published by nova.
What does the result look like?
What can I customize?
Your choices go into the line you copy. Anything else is yours to edit, but it leaves the tested path.
What do I get?
-
spec.mdRequirements and acceptance checks.Fluid lander
What this builds
A side-on lander game. The craft has mass, fuel, and a downward and a sideways thruster. The exhaust is not a sprite: it is injected into a fluid field, and if atmosphere is on the field already has a slight density. The field is stepped with a documented solver at a fixed timestep. A landing or a crash is decided by the craft's motion, not by a hidden script. Tests use a fixed timestep and a seed so a landing and a crash are deterministic.
Read
spekkr.inputs.jsonfirst.gravityandfuelset the craft.atmosphereandplumechange the field and the picture.solverchooses how the field is stepped.Out of scope
- A 3D world or a real-time NASA-grade solver.
- Network or a replay server in the checks.
- A physical wind tunnel.
Requirements
Each requirement has an id. Checks name the id they cover.
R1. The craft
- The lander is a 4 m tall, 2 m wide rectangle. Dry mass 200 kg plus
fuel. Thrust is 800 N downward and 200 N sideways, burning 0.6 kg/s when a downward thruster is on and 0.15 kg/s when a side thruster is on. - The timestep is 1/60 s. Integration is semi-implicit Euler.
- A soft landing is a contact with a pad with vertical speed under 2 m/s and tilt under 8 degrees. Anything else that hits terrain is a crash.
Accept when: the vacuum ballistic drop in
design.md(thrusters off, atmosphere off) matches the closed form within 0.05 m after 2 s.R2. The field
- The fluid is a 128 by 96 staggered grid over a 64 by 48 m world. Density and velocity are stored. The chosen solver steps the field each tick.
- A downward burn injects density and downward momentum at the listed nozzle cells.
- A residual check after 60 steps of the rest-state fixture (no craft, atmosphere on or off as listed) stays under the bound in
design.md. A mass-check on a closed box with no inflow stays within 1% of the starting mass.
Accept when: the rest-state residual and the closed-box mass check pass for both solvers.
R3. Landing and crash fixtures
fixtures/lander-soft.jsonis a control tape that, from the documented start, produces a soft landing on pad A at t = 8.0 s, with the pose in the file.fixtures/lander-crash.jsonproduces a crash on the slope at t = 5.2 s.- Both are deterministic at timestep 1/60 with atmosphere on, seed 1.
Accept when: the soft fixture is a soft landing at the pose in the file, the crash fixture is a crash at the listed place, and a second run of each hashes the same pose trail.
R4. Frames and files
- Four frames: approach at t = 2 s of the soft tape, plume-on at t = 4 s, soft-landing at contact, crash at contact of the crash tape.
- One command runs the ballistic, residual, mass, and tape tests, and writes the frames. No network.
Accept when: the command passes for both solvers, and the frames match the goldens.
R5. Inputs
- The build reads
spekkr.inputs.json. Settings label the UI, options turn features on or off, and a swap must be one of its choices. - A value outside a stated range, or a swap that is not one of its choices, is refused before the app starts its checks, with a message that names the key.
Accept when: the default inputs render, an illegal swap is refused by name, and changing a visible setting (for example the title) shows up in a later check.
Verification
A deterministic landing fixture and a crash fixture, both at a fixed timestep, produce the documented poses and outcomes. The fluid field has a residual check and a closed-box mass check for both solvers. Golden frames cover approach, plume, landing and crash. No physical tunnel and no network.
Definition of done
- Every acceptance check above runs from one command, and all pass at the person's inputs.
- A README says how to fly, how to run the tapes, and how to switch the solver.
# Fluid lander ## What this builds A side-on lander game. The craft has mass, fuel, and a downward and a sideways thruster. The exhaust is not a sprite: it is injected into a fluid field, and if atmosphere is on the field already has a slight density. The field is stepped with a documented solver at a fixed timestep. A landing or a crash is decided by the craft's motion, not by a hidden script. Tests use a fixed timestep and a seed so a landing and a crash are deterministic. Read `spekkr.inputs.json` first. `gravity` and `fuel` set the craft. `atmosphere` and `plume` change the field and the picture. `solver` chooses how the field is stepped. ## Out of scope - A 3D world or a real-time NASA-grade solver. - Network or a replay server in the checks. - A physical wind tunnel. ## Requirements Each requirement has an id. Checks name the id they cover. ### R1. The craft - The lander is a 4 m tall, 2 m wide rectangle. Dry mass 200 kg plus `fuel`. Thrust is 800 N downward and 200 N sideways, burning 0.6 kg/s when a downward thruster is on and 0.15 kg/s when a side thruster is on. - The timestep is 1/60 s. Integration is semi-implicit Euler. - A soft landing is a contact with a pad with vertical speed under 2 m/s and tilt under 8 degrees. Anything else that hits terrain is a crash. Accept when: the vacuum ballistic drop in `design.md` (thrusters off, atmosphere off) matches the closed form within 0.05 m after 2 s. ### R2. The field - The fluid is a 128 by 96 staggered grid over a 64 by 48 m world. Density and velocity are stored. The chosen solver steps the field each tick. - A downward burn injects density and downward momentum at the listed nozzle cells. - A residual check after 60 steps of the rest-state fixture (no craft, atmosphere on or off as listed) stays under the bound in `design.md`. A mass-check on a closed box with no inflow stays within 1% of the starting mass. Accept when: the rest-state residual and the closed-box mass check pass for both solvers. ### R3. Landing and crash fixtures - `fixtures/lander-soft.json` is a control tape that, from the documented start, produces a soft landing on pad A at t = 8.0 s, with the pose in the file. - `fixtures/lander-crash.json` produces a crash on the slope at t = 5.2 s. - Both are deterministic at timestep 1/60 with atmosphere on, seed 1. Accept when: the soft fixture is a soft landing at the pose in the file, the crash fixture is a crash at the listed place, and a second run of each hashes the same pose trail. ### R4. Frames and files - Four frames: approach at t = 2 s of the soft tape, plume-on at t = 4 s, soft-landing at contact, crash at contact of the crash tape. - One command runs the ballistic, residual, mass, and tape tests, and writes the frames. No network. Accept when: the command passes for both solvers, and the frames match the goldens. ### R5. Inputs - The build reads `spekkr.inputs.json`. Settings label the UI, options turn features on or off, and a swap must be one of its choices. - A value outside a stated range, or a swap that is not one of its choices, is refused before the app starts its checks, with a message that names the key. Accept when: the default inputs render, an illegal swap is refused by name, and changing a visible setting (for example the title) shows up in a later check. ## Verification A deterministic landing fixture and a crash fixture, both at a fixed timestep, produce the documented poses and outcomes. The fluid field has a residual check and a closed-box mass check for both solvers. Golden frames cover approach, plume, landing and crash. No physical tunnel and no network. ## Definition of done - Every acceptance check above runs from one command, and all pass at the person's inputs. - A README says how to fly, how to run the tapes, and how to switch the solver.
-
design.mdThe craft, the fluid checks, and the landing and crash tapes.Design
This file fixes the parts that are easy to get wrong. The language and tools are up to you, as long as the numbers here hold.
World
Origin at the lower left. Pad A is a 8 m wide flat at z = 0, from x = 28 to 36. Terrain otherwise follows
fixtures/lander-terrain.json.Ballistic drop
Start x = 32, z = 30, velocity 0, thrusters off, atmosphere off. After 2 s, z = 30 - 0.5 * gravity * 4. At default gravity 1.62, z = 23.52 m. Tolerance 0.05 m.
Residuals
Rest-state, 60 steps, no injection: the L2 of velocity increment per step, mean over the last 10 steps, is under 1e-4 for
stable-fluidsand under 5e-4 forlattice-boltzmann. Closed-box mass (atmosphere on, no craft) stays within 1% of the start.Tapes
The two fixture files are the authority for poses and for the pass/fail result. Goldens are 1600 by 1000, tolerance 8 levels, 98% of pixels (the plume may use a 12-level tolerance in the overlay region defined in
fixtures/plume-mask.png).Inputs
Key Label Default Notes gravityGravity, m/s² 1.62 A positive number. The default is a small moon. fuelFuel mass, kg 80 From 20 to 200. The lander dry mass is 200 kg. atmosphereThin atmosphere on A background fluid field the exhaust pushes through. If off, exhaust still exists as a jet into vacuum. plumeDraw the plume on The fluid field is visible as a density overlay. solverSolver stable-fluids Two ways to step the field. Both must pass the same residual checks within their tolerances. Acceptance at the defaults
The numbers, names and fixture paths already in this file are the authority. Where a later table or a shipped fixture file disagrees with prose, the table or the fixture wins.
Fixture Role design.mdA shipped fixture. The build may move it, but then design.mdmust name the new path.fixtures/lander-crash.jsonA shipped fixture. The build may move it, but then design.mdmust name the new path.fixtures/lander-soft.jsonA shipped fixture. The build may move it, but then design.mdmust name the new path.fixtures/lander-terrain.jsonA shipped fixture. The build may move it, but then design.mdmust name the new path.spekkr.inputs.jsonA shipped fixture. The build may move it, but then design.mdmust name the new path.Golden frames are compared at 1400 by 1000 CSS pixels unless a requirement names another size. Tolerance, unless a tighter figure is given above: 8 levels, 98% of pixels, with motion, cursors and clocks frozen as this file says. A build's goldens are of that build; they do not have to match a shipped reference preview pixel-for-pixel if the tool or the type is different, but they do have to match this file's layout, counts and copy.
Screenshots
These pictures are headless-Chrome captures of the working reference in
reference/preview.html, at the default inputs. They are not drawings of a product that has not been built. The first picture is the one Spekkr shows on the spec's card. A build may ship its own goldens; those goldens are of that build and do not have to match these frames pixel-for-pixel.File What it shows shots/approach.pngThe lander at 142 m, exhaust in the CFD field, the pad below. How to verify
- Run the checks at the default inputs, without a network.
- Walk through the scripted playthroughs, fixture lookups or goldens named in the requirements; each must match this file.
- Repeat once at the person's inputs when they differ from the defaults.
- A deterministic landing fixture and a crash fixture, both at a fixed timestep, produce the documented poses and outcomes. The fluid field has a residual check and a closed-box mass check for both solvers. Golden frames cover approach, plume, landing and crash. No physical tunnel and no network.
# Design This file fixes the parts that are easy to get wrong. The language and tools are up to you, as long as the numbers here hold. ## World Origin at the lower left. Pad A is a 8 m wide flat at z = 0, from x = 28 to 36. Terrain otherwise follows `fixtures/lander-terrain.json`. ## Ballistic drop Start x = 32, z = 30, velocity 0, thrusters off, atmosphere off. After 2 s, z = 30 - 0.5 * gravity * 4. At default gravity 1.62, z = 23.52 m. Tolerance 0.05 m. ## Residuals Rest-state, 60 steps, no injection: the L2 of velocity increment per step, mean over the last 10 steps, is under 1e-4 for `stable-fluids` and under 5e-4 for `lattice-boltzmann`. Closed-box mass (atmosphere on, no craft) stays within 1% of the start. ## Tapes The two fixture files are the authority for poses and for the pass/fail result. Goldens are 1600 by 1000, tolerance 8 levels, 98% of pixels (the plume may use a 12-level tolerance in the overlay region defined in `fixtures/plume-mask.png`). ## Inputs | Key | Label | Default | Notes | | --- | --- | --- | --- | | `gravity` | Gravity, m/s² | 1.62 | A positive number. The default is a small moon. | | `fuel` | Fuel mass, kg | 80 | From 20 to 200. The lander dry mass is 200 kg. | | `atmosphere` | Thin atmosphere | on | A background fluid field the exhaust pushes through. If off, exhaust still exists as a jet into vacuum. | | `plume` | Draw the plume | on | The fluid field is visible as a density overlay. | | `solver` | Solver | stable-fluids | Two ways to step the field. Both must pass the same residual checks within their tolerances. | ## Acceptance at the defaults The numbers, names and fixture paths already in this file are the authority. Where a later table or a shipped fixture file disagrees with prose, the table or the fixture wins. | Fixture | Role | | --- | --- | | `design.md` | A shipped fixture. The build may move it, but then `design.md` must name the new path. | | `fixtures/lander-crash.json` | A shipped fixture. The build may move it, but then `design.md` must name the new path. | | `fixtures/lander-soft.json` | A shipped fixture. The build may move it, but then `design.md` must name the new path. | | `fixtures/lander-terrain.json` | A shipped fixture. The build may move it, but then `design.md` must name the new path. | | `spekkr.inputs.json` | A shipped fixture. The build may move it, but then `design.md` must name the new path. | Golden frames are compared at 1400 by 1000 CSS pixels unless a requirement names another size. Tolerance, unless a tighter figure is given above: 8 levels, 98% of pixels, with motion, cursors and clocks frozen as this file says. A build's goldens are of that build; they do not have to match a shipped reference preview pixel-for-pixel if the tool or the type is different, but they do have to match this file's layout, counts and copy. ## Screenshots These pictures are headless-Chrome captures of the working reference in `reference/preview.html`, at the default inputs. They are not drawings of a product that has not been built. The first picture is the one Spekkr shows on the spec's card. A build may ship its own goldens; those goldens are of that build and do not have to match these frames pixel-for-pixel. | File | What it shows | | --- | --- | | `shots/approach.png` | The lander at 142 m, exhaust in the CFD field, the pad below. | ## How to verify 1. Run the checks at the default inputs, without a network. 2. Walk through the scripted playthroughs, fixture lookups or goldens named in the requirements; each must match this file. 3. Repeat once at the person's inputs when they differ from the defaults. 4. A deterministic landing fixture and a crash fixture, both at a fixed timestep, produce the documented poses and outcomes. The fluid field has a residual check and a closed-box mass check for both solvers. Golden frames cover approach, plume, landing and crash. No physical tunnel and no network.
-
tasks.mdBuild tasks in order, each with a check.Tasks
Work in order. Finish a task's check before starting the next.
- Set up. Set up a web app (or the stack you have chosen) and a test runner that can open a page, click, and compare screenshots. Read
spekkr.inputs.jsonfirst. Check: a blank or heading page loads, and an empty test run passes. - The craft (R1). Build what
R1. The craftasks for, to the numbers indesign.md. In particular: The lander is a 4 m tall, 2 m wide rectangle. Dry mass 200 kg plusfuel. Thrust is 800 N downward and 200 N sideways, burning 0.6 kg/s when a downward thruster is on and 0.15 kg/s when a side thruster is on. Check: theR1. The craftacceptance checks pass. - The field (R2). Build what
R2. The fieldasks for, to the numbers indesign.md. In particular: The fluid is a 128 by 96 staggered grid over a 64 by 48 m world. Density and velocity are stored. The chosen solver steps the field each tick. Check: theR2. The fieldacceptance checks pass. - Landing and crash fixtures (R3). Build what
R3. Landing and crash fixturesasks for, to the numbers indesign.md. In particular:fixtures/lander-soft.jsonis a control tape that, from the documented start, produces a soft landing on pad A at t = 8.0 s, with the pose in the file. Check: theR3. Landing and crash fixturesacceptance checks pass. - Frames and files (R4). Build what
R4. Frames and filesasks for, to the numbers indesign.md. In particular: Four frames: approach at t = 2 s of the soft tape, plume-on at t = 4 s, soft-landing at contact, crash at contact of the crash tape. Check: theR4. Frames and filesacceptance checks pass. - Inputs (R5). Build what
R5. Inputsasks for, to the numbers indesign.md. In particular: The build readsspekkr.inputs.json. Settings label the UI, options turn features on or off, and a swap must be one of its choices. Check: theR5. Inputsacceptance checks pass. - Goldens. Capture the frames named in
design.mdat the defaults, with motion frozen where the file says so. Compare them within the stated tolerance. Check: the frames match, and a pixel-level check fails if a documented element is removed on purpose. - Finish. Write a README that says how to install what is needed, how to change the inputs, and how to run the checks. Run the one command from a clean folder. Check: every item under Definition of done in
spec.mdis true.
# Tasks Work in order. Finish a task's check before starting the next. 1. **Set up.** Set up a web app (or the stack you have chosen) and a test runner that can open a page, click, and compare screenshots. Read `spekkr.inputs.json` first. Check: a blank or heading page loads, and an empty test run passes. 2. **The craft (R1).** Build what `R1. The craft` asks for, to the numbers in `design.md`. In particular: The lander is a 4 m tall, 2 m wide rectangle. Dry mass 200 kg plus `fuel`. Thrust is 800 N downward and 200 N sideways, burning 0.6 kg/s when a downward thruster is on and 0.15 kg/s when a side thruster is on. Check: the `R1. The craft` acceptance checks pass. 3. **The field (R2).** Build what `R2. The field` asks for, to the numbers in `design.md`. In particular: The fluid is a 128 by 96 staggered grid over a 64 by 48 m world. Density and velocity are stored. The chosen solver steps the field each tick. Check: the `R2. The field` acceptance checks pass. 4. **Landing and crash fixtures (R3).** Build what `R3. Landing and crash fixtures` asks for, to the numbers in `design.md`. In particular: `fixtures/lander-soft.json` is a control tape that, from the documented start, produces a soft landing on pad A at t = 8.0 s, with the pose in the file. Check: the `R3. Landing and crash fixtures` acceptance checks pass. 5. **Frames and files (R4).** Build what `R4. Frames and files` asks for, to the numbers in `design.md`. In particular: Four frames: approach at t = 2 s of the soft tape, plume-on at t = 4 s, soft-landing at contact, crash at contact of the crash tape. Check: the `R4. Frames and files` acceptance checks pass. 6. **Inputs (R5).** Build what `R5. Inputs` asks for, to the numbers in `design.md`. In particular: The build reads `spekkr.inputs.json`. Settings label the UI, options turn features on or off, and a swap must be one of its choices. Check: the `R5. Inputs` acceptance checks pass. 7. **Goldens.** Capture the frames named in `design.md` at the defaults, with motion frozen where the file says so. Compare them within the stated tolerance. Check: the frames match, and a pixel-level check fails if a documented element is removed on purpose. 8. **Finish.** Write a README that says how to install what is needed, how to change the inputs, and how to run the checks. Run the one command from a clean folder. Check: every item under Definition of done in `spec.md` is true.
- Set up. Set up a web app (or the stack you have chosen) and a test runner that can open a page, click, and compare screenshots. Read
-
reference/preview.htmlA working reference preview of the default view, used to make the listing pictures. A build does not have to start from this file. -
reference/fonts/fonts.cssWebfont faces for the reference preview. -
reference/fonts/Geist.ttfGeist variable typeface for the reference preview. -
reference/fonts/GeistMono.ttfGeist Mono variable typeface for the reference preview. -
reference/fonts/Fraunces.ttfFraunces variable typeface for the reference preview. -
reference/fonts/Fraunces-Italic.ttfFraunces italic variable typeface for the reference preview.
Is it for me?
- Kind
- browser game
- Platforms
- web
- Tools
- TypeScript, WebGL
What does it need?
- Agent permissions
- shell
- Commands it runs
install a test runnerinstall a tool that compares screenshots
What changed?
- 0.2.215 Nov 2026Names what it builds.
- 0.2.114 Nov 2026Add animated loop to the listing shots.
- 0.2.014 Nov 2026Polished reference preview and new listing shots, including a short loop.
- 0.1.014 Nov 2026First version.
For agents: start.md says how to build this spec, spec.json holds everything on this page, and bundle.tar.gz holds its files.