Reader sniffs the first byte (0x49 raw-ISLA v2 vs 0x07 v1 string prefix) and routes to the v2 tagged-section parser or the intact v1 path (v1 loads log a deprecation warning — fallback stays live). v2 validation: magic/version gate (loud reject), MapSize sanity bound [256, 32768] before allocation, every section length checked against remaining file, section-consumed-exactly check, params-first and no-duplicate-section rules, biome and town-tier ordinal range checks. Unknown tags skip by length — the forward-compat property D-030 buys. ServerChunkManager cross-checks embedded params against config (seed + MapSize) and logs a prominent desync warning — canon H7's silent failure becomes loud. ServerConfig.json pins the reference world: WorldSeed 1409879727, 8K. Round-trip oracle GREEN: reference v1 (537,054,156 B) -> v2 (335,727,522 B, -192 MB) -> parse -> semantic equality holds (heights bitwise, biomes, 94 towns, 4/1/37/39 road paths point-for-point). v1 parse 1.9s, v2 write 1.4s, v2 parse 1.6s. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| BiomePalette.cs | ||
| BiomePalette.cs.uid | ||
| BlockData.cs | ||
| BlockData.cs.uid | ||
| BlockRegistry.cs | ||
| BlockRegistry.cs.uid | ||
| BlueprintFormat.cs | ||
| BlueprintWriter.cs | ||
| ChunkData.cs | ||
| ChunkData.cs.uid | ||
| ConfigManager.cs | ||
| ConfigManager.cs.uid | ||
| Constants.cs | ||
| Constants.cs.uid | ||
| Enums.cs | ||
| Enums.cs.uid | ||
| MapDataParser.cs | ||
| MapDataParser.cs.uid | ||
| MarchingCubes.cs | ||
| MarchingCubes.cs.uid | ||
| MATH_MARCHING_CUBES.md | ||
| README.md | ||
/Core/Scripts
Pure C# data structures, shared enums, and static maths. Compiled into the shared assembly used by
both /Server and /Client.
"Pure data, zero state." These scripts define what things are and how to calculate them. They never track live game events — who is online, which chunks are loaded, what time it is.
What's actually here
Voxel materials
BlockData.cs— struct describing one block type (ID, name, IsSolid, BaseColor).BlockRegistry.cs— the byte-ID master list (AIR0,BEDROCK,STONE,DIRT,SAND, the three grasses,SNOW,WASTELAND_DIRT,ASPHALT) with a safeGetBlocklookup.BiomePalette.cs— decides which material sits where, given biome, depth, and whether the column is roadbed. Two paths on purpose: an integer classification that decides what is stored in each voxel, and a float-depth version used for rendering that returns the two materials either side of a boundary so colours fade rather than snap.
⚠ Note that BlockRegistry and the mesher's colour table hold different RGB values for some
blocks. The mesher's table is what you actually see; BlockData.BaseColor is currently unused by
rendering.
Shared identifiers
-
Enums.cs—Biome,TownTier,MapHalf,RoadTier.⚠
BiomeandTownTierare the.datwire format. They are declared without explicit values, so each member's ordinal is the number written to disk, with no version gate and no validation on read. Append only, at the end — never reorder or insert. Doing so silently reinterprets every pixel and every settlement in every existing blueprint.RoadTieris exempt: road tiers live in separate sections of the file, so it is never serialized.
World data
MapDataParser.cs— decodes the.datblueprint into aWorldBlueprint(heightmap, biome map, towns, four road tiers).ChunkData.cs— one chunk's density and block-ID fields,+1padded on every axis so the mesher can reach into the neighbouring chunk, plus the per-column data the renderer needs.Constants.cs— chunk dimensions,ISO_LEVEL,VOXEL_SCALE, and the visual/road tunables (material blend band; per-tier road width, shoulder, grade smoothing and surface).
Maths
MarchingCubes.cs— density field →ArrayMesh, with analytical normals and deterministic integer-keyed vertex welding.MATH_MARCHING_CUBES.md— an explainer of the algorithm.
Rules
- No Godot node inheritance. Pure classes, structs and statics.
- No
_Process/_Ready. Nothing here is attached to a live scene object. - Dependencies flow inward only.
/Serverand/Clientreference/Core;/Corenever references them.