diff --git a/level/chunk.go b/level/chunk.go index 8d258b1..24d6ded 100644 --- a/level/chunk.go +++ b/level/chunk.go @@ -190,6 +190,9 @@ func ChunkToSave(c *Chunk, dst *save.Chunk) (err error) { s.BlockLight = v.BlockLight } dst.Sections = sections + if dst.Heightmaps == nil { + dst.Heightmaps = make(map[string][]uint64) + } dst.Heightmaps["WORLD_SURFACE_WG"] = c.HeightMaps.WorldSurfaceWG.Raw() dst.Heightmaps["WORLD_SURFACE"] = c.HeightMaps.WorldSurface.Raw() dst.Heightmaps["OCEAN_FLOOR_WG"] = c.HeightMaps.OceanFloorWG.Raw()