Bake, then wire
Bake a spec into a folder, then wire the bake into a Godot 4 scene. The scene must sit inside a Godot project, so put the bake folder inside the project first.
spatial-compiler bake <name>.pyro.toml --out <dir>
spatial-compiler wire <dir> --scene <path>.tscn
wire installs the six-way shader flipbook_6way.gdshader and pyro_sheet.gd in the project and writes texture import settings. It also writes a scene whose root is a quad sized in meters, with its origin on the ground under the effect. The scene plays on its own, or you can set autoplay = false and drive time_s from the sim clock. --set node=particles writes a GPUParticles3D instead, for many copies.
Commands
spatial-compiler schema- Prints every field, range, default, warning and metric as JSON. When the docs and the tool disagree, trust
schema. spatial-compiler check <spec>- Validates a spec without touching the GPU. Each error names the key and the nearest valid key or the range.
spatial-compiler bake <spec> --out <dir> [--quality draft|final] [--seed n] [--set k=v]- Bakes the spec. Draft doubles the cell size, so it is softer and carries the expected warning
GRID_REDUCED. spatial-compiler sweep <spec> --set key=v1,v2 --out <dir>- Bakes variants at draft quality onto one labelled comparison sheet,
sweep_sheet.png, at most 16 variants. spatial-compiler version- Prints the version.
--set section.key=value overrides one field. For [[emitters]] and [[views]], emitters.fuel=3 sets every row and emitters.0.fuel=3 sets the first.
Exit codes are 0 for done, 1 for an invalid spec or arguments, 2 for a GPU failure and 3 for a file error.
The loop
- Copy the nearest example and run
spatial-compiler checkon it. - Bake at draft quality and read
warnings; change the key eachfix.hintnames. - Open
preview_strip.pngand judge the look. - Use
sweepto compare two or three values of one or two keys. - Bake at final quality until the report shows
"ok": trueand no warnings, then wire it.