1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-10-12 16:15:20 +02:00

Fix incorrect MapgenV6 chunk size warning

This commit is contained in:
sfan5
2025-10-05 17:11:04 +02:00
parent f2be1c39c8
commit 61f3812f73
2 changed files with 2 additions and 1 deletions

View File

@@ -165,6 +165,7 @@ public:
u32 blockseed; u32 blockseed;
s16 *heightmap = nullptr; s16 *heightmap = nullptr;
biome_t *biomemap = nullptr; biome_t *biomemap = nullptr;
// Chunk size in nodes
v3s16 csize; v3s16 csize;
BiomeGen *biomegen = nullptr; BiomeGen *biomegen = nullptr;

View File

@@ -49,7 +49,7 @@ MapgenV6::MapgenV6(MapgenV6Params *params, EmergeParams *emerge)
// (5,2,5) generates very broken terrain // (5,2,5) generates very broken terrain
throw BaseException("MapgenV6: chunk size must be cubic"); throw BaseException("MapgenV6: chunk size must be cubic");
} }
if (csize.Y % 2 == 0) { if (csize.Y % (MAP_BLOCKSIZE * 2) == 0) {
// weird ledges appear in some places // weird ledges appear in some places
warningstream << "MapgenV6: chunk heights divisible by two are known " warningstream << "MapgenV6: chunk heights divisible by two are known "
"to be buggy." << std::endl; "to be buggy." << std::endl;