magicciv/.project/objectives/p2-51-world-shape-knobs.md
Natalie a7662c2e08 feat(@projects/@magic-civilization): add new objective categories
Co-Authored-By: Lilith Autocommit <noreply@atlilith.com>
2026-05-01 01:50:19 -04:00

3.9 KiB
Raw Blame History

id title priority status scope owner updated_at canonical_doc coordinates_with evidence
p2-51 Player-facing world-shape parameters on new-game screen p2 partial game1 terraformer 2026-04-30 public/games/age-of-dwarves/docs/terrain/WORLDGEN_PRESETS.md
p1-10
p1-50
p2-49
src/simulator/crates/mc-mapgen/src/world_shape.rs
src/simulator/crates/mc-mapgen/tests/world_shape_compose.rs
public/games/age-of-dwarves/data/world_shapes/manifest.json
src/game/engine/scenes/tests/world_shape_preview.tscn

Summary

The terraformer pipeline now exposes ~15 internal parameters (plate count, tectonic strength, fbm octaves, sea level, latitude gradient, continentality decay, rain-shadow factor, erosion iterations, drainage threshold, etc.). Designers tune these in the forest lab; players see none of them. The new-game screen ships "Map Size" and not much else.

Industry baseline (Civ 6, Old World, Songs of Conquest) exposes 46 high-level shape knobs. Each knob is a preset that derives several internal parameters at once. This objective wires that surface from JSON presets through mc-mapgen parameters into the Godot game-setup scene.

Acceptance

  • JSON preset cataloguepublic/games/age-of-dwarves/data/world_shapes/ fully authored: 20 per-axis preset JSON files + manifest.json. Axes: landmass (5), climate (4), moisture (5), age (3), sea_level (3).
  • mc-mapgen consumes presetsWorldShape struct + WorldgenParams in mc-mapgen/src/world_shape.rs. MapGenerator::generate_with_shape() wires plate_count/convergent_bias/divergent_bias into run_tectonics_with_overrides, temp_offset/latitude_gradient/windward_boost/ seasonality_scale/rain_shadow_factor/base_precip_offset into ClimateParams, erosion_iterations into ErosionParams. GDExt bridge: GdMapGenerator::generate_with_shape. WASM bridges: composeWorldShapeJson, generateForLabWithShape.
  • Determinism testmc-mapgen/tests/world_shape_compose.rs: 11 tests (60-combo determinism sweep + 10 golden character assertions). All passing.
  • Game-setup scene dropdowns — logic wired in game_setup.gd (5 dropdowns + _collect_world_shape()build_settings()). Scene .tscn node references (%LandmassOption etc.) pending Godot scene editor pass to add the actual OptionButton nodes. Falls back gracefully (has_node guard) until scene is wired.
  • Preview thumbnails — proof scene authored at scenes/tests/world_shape_preview.tscn/.gd. Thumbnails must be rendered on apricot via SCREENSHOT_SCENE=world_shape_preview + tools/screenshot.sh. PNG output path: public/games/age-of-dwarves/data/world_shapes/previews/<id>.png. Pending headless Godot run.
  • Lab parityPresets.tsx WASM wiring is Wave-E / p1-53 Stage 2 territory (layer-pages-wasm-wiring agent). Relocated per Wave-D closing checklist.
  • Visual proof — proof scene authored at src/game/engine/scenes/tests/world_shape_preview.tscn; renders 5 preset composites (earthlike, pangaea_hot_arid, archipelago_temperate_wet, shattered_cold_lush, continents_extreme_dry) via generate_with_shape(). Screenshot capture pending operator pass on apricot via tools/screenshot.sh per phase-gate-protocol.md. PNGs not yet committed to public/games/age-of-dwarves/data/world_shapes/previews/.

Non-goals

  • Custom-script map types (e.g. "Donut", "Spiral") — defer.
  • Map-script Lua/GDScript user mods — defer to post-Game-1.
  • Hand-authored named-world templates (e.g. "Earth"). Possible later.
  • Map-size presets — already covered by existing scene.

Dependencies

  • p1-50 (tectonics): landmass knob bias the plate distribution.
  • p2-49 (climate axes): climate and moisture knobs map to latitude gradient + base humidity.
  • p2-50 (RNG pin): preset-driven generation must be reproducible.
  • Coordinate with p1-10 (game-setup-ux) for the Godot scene integration.