mirror of
https://github.com/Pumpkin-MC/Pumpkin.git
synced 2026-08-30 20:14:23 +00:00
`AnvilLevelInfo::read_world_info` validated the version tags and then returned `LevelData::default(Seed(0))`, so level name, difficulty, spawn, world border and data packs were discarded on every start, and the writer emitted only `DataVersion`, `version` and `LastPlayed`, truncating the rest on save. A world whose seed lives in level.dat's legacy `Data.WorldGenSettings` compound, as converters such as Chunker emit, therefore loaded with seed 0 and generated foreign terrain into its existing region files. level.dat is now read and written tag by tag through pumpkin-nbt, every field falling back to its vanilla default, so a missing optional tag such as `Version.Series` no longer costs the whole file. Saving merges into the existing `Data` compound, so tags Pumpkin does not model survive. A world with no seed in either file aborts startup instead of silently regenerating, and the seed is mirrored into level.dat, the only world file that is backed up. Version tags are re-stamped with the current constants on save so level.dat stays consistent with the chunks Pumpkin writes.