Add map inspector that emits a human-readable stats report

Counts set vs empty cells per layer, lists the top-10 most frequent
non-empty GIDs with decoded components, and reports roof coverage.
When an atlas registry is supplied, atlas-id+tile-name annotations
are added; without one the report still works using indices only.
This commit is contained in:
Axel Meyer
2026-05-23 16:55:56 +02:00
parent f516e2acda
commit 530bceaddd
4 changed files with 193 additions and 0 deletions

View File

@@ -0,0 +1,30 @@
{
"schema_version": 2,
"id": "inspect_sample",
"size": { "w": 4, "h": 4 },
"atlases": ["atlas_a", "atlas_b"],
"layers": {
"surface": {
"tiles": [
16, 16, 16, 16,
16, 32, 32, 16,
16, 32, 32, 16,
16, 16, 16, 16
]
},
"wall": {
"tiles": [
16777232, 16777232, 16777232, 16777232,
16777232, 0, 0, 16777232,
16777232, 0, 0, 16777232,
16777232, 16777232, 16777232, 16777232
]
}
},
"roof": [
0, 0, 0, 0,
0, 1, 1, 0,
0, 1, 1, 0,
0, 0, 0, 0
]
}