feat(dashboard): 3D views show a zone's scenes as the game loads them

A "Scenes" choice in the world and property 3D views: every scene (as
before), the scenes the game keeps loaded around the camera or the followed
player (the scene under it from the terrain's scene map, the scenes its
transitions connect to, and the global scene, following as it moves), or
scenes picked from a list (world view). The lighting blends to the lighting
of the scene under the focus, as the client blends between scenes.

The scenery manifest now carries each object's scene, the zone's scenes with
their neighbours and lighting, and the scene map as runs (37 KB for Avant
Gardens); scenery-core.js finds the scene at a point exactly as ZoneScenes
does (checked against it on 2000 points of Avant Gardens).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Aaron Kimbrell
2026-09-27 22:13:22 -05:00
parent 83b87744c1
commit 2da96ada83
12 changed files with 318 additions and 15 deletions

View File

@@ -83,3 +83,18 @@ namespace ZoneScenes {
return loaded;
}
}
namespace ZoneScenes {
std::string RunLengths(const std::vector<uint8_t>& cells, size_t count) {
count = std::min(count, cells.size());
std::string runs;
for (size_t i = 0; i < count;) {
size_t length = 1;
while (i + length < count && length < 255 && cells[i + length] == cells[i]) length++;
runs.push_back(static_cast<char>(length));
runs.push_back(static_cast<char>(cells[i]));
i += length;
}
return runs;
}
}