fix: keep the scene map of version 31 and older raws

These files have a (resolution + 1)^2 scene map, kept in sceneMapLegacy. Version 31 uses its first resolution rows and columns; older versions are all scene 0, as in the client.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Aaron Kimbrell
2026-10-26 20:33:41 -05:00
parent 6262be5d25
commit a40169a251
4 changed files with 28 additions and 34 deletions

View File

@@ -98,6 +98,9 @@ struct Chunk {
// The scene map is colorMapResolution * colorMapResolution scene IDs, indexed [x cell * resolution + z cell]
std::vector<uint8_t> sceneMap;
// Version 31 and older: the file's (colorMapResolution + 1)^2 scene map. In version 31 sceneMap is its first
// colorMapResolution rows and columns; older versions don't use it and every cell is scene 0
std::vector<uint8_t> sceneMapLegacy;
// Mesh data (version 32+)
uint32_t vertSize = 0;