terrainSystem
Author terrain end to end — spawn it, sculpt its heightmap, save and load it, sample its surface, and scatter props across it.
Spawn a terrain entity from an asset, from FBM noise, from an existing handle, or as a flat baseline, and destroy it (leaving the on-disk asset untouched). Edit the heightmap across a broad vocabulary: the painter ops (raise, lower, flatten, smooth, set), procedural authoring (cone, ridge, valley, plateau, ramp, terrace, noise), and pseudo-hydraulic erosion — the mesh rebuilds on every edit, and you can persist and refresh a live entity in the same call. Save a terrain to a .terrain asset or load one back. Query the surface for height, normal, or slope at a point, or read its metadata. Scatter mesh instances by rule — slope cutoff, altitude band, noise mask, density, jitter, and yaw/scale variation. Edits, queries, persistence, and scatter all accept a handle, an entity, or a .terrain asset ref uniformly; the toolbox holds no state, so callers keep the current handle or path and re-supply it.
Scoped to this part · feeds back into the world's score.