feat(simulation): serve the coarse district/morphology grid through the Atlas proxy (T-1046)

Server half of wiring the derived tier into production. The D-225 proxy
(AtlasLayerResponse) carried only Layer1Output, so the Atlas could not show the
DistrictProfile tier that the cascade derives. Adds DistrictGridLayer (cols/rows
+ row-major MorphologyZone discriminants + elev_q for relief shading) and
build_district_grid(), populated on a cache hit. Because the response is
rmp_serde msgpack end-to-end, the new field reaches the client automatically.

This is the planetary-scale coarse grid (the Atlas map view); the on-demand 2km
derive_district (T-1077) is for in-world Phase 5, not the map. MorphologyZone
gains Copy (fieldless repr(u8) enum; additive).

Next: client decode (protocol.gd) + the D-226 generation overlay in the Atlas
viewer.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-06-15 12:30:47 +02:00
co-authored by Claude Opus 4.8
parent d1fa785678
commit d03b4d1e09
7 changed files with 159 additions and 4 deletions
+3
View File
@@ -571,6 +571,7 @@ fn generate_atlas_layer_response_fixtures() {
body_id: "GJ1c".into(),
status: AtlasLayerStatus::Ready,
layer1: Some(layer1),
district_grid: None,
};
write_fixture(
"atlas_response_ready",
@@ -581,6 +582,7 @@ fn generate_atlas_layer_response_fixtures() {
body_id: "GJ1c".into(),
status: AtlasLayerStatus::Pending,
layer1: None,
district_grid: None,
};
write_fixture(
"atlas_response_pending",
@@ -591,6 +593,7 @@ fn generate_atlas_layer_response_fixtures() {
body_id: "ghost".into(),
status: AtlasLayerStatus::NotFound,
layer1: None,
district_grid: None,
};
write_fixture(
"atlas_response_not_found",