fix(gameplay): re-enable border blending and protect water in cave gen

This commit is contained in:
2026-06-12 09:57:28 +08:00
parent 623f991fcf
commit 04900a05fd
2 changed files with 5 additions and 1 deletions

View File

@@ -199,7 +199,7 @@ void Chunk::gen_phase_six(
Logger::error("ChunkGenerator is Nullptr");
return;
}
// m_generator->blend_surface_blocks_borders(neighbor_block);
m_generator->blend_surface_blocks_borders(neighbor_block);
m_generator->generate_cave();
m_generator->generate_river();
}

View File

@@ -688,6 +688,10 @@ void ChunkGenerator::generate_cave() {
if (blocks[Chunk::index(x, y, z)] == 7) {
continue;
}
if (y < WORLD_SIZE_Y - 1 &&
blocks[Chunk::index(x, y + 1, z)] == 7) {
continue;
}
blocks[Chunk::index(x, y, z)] = 0;
}
}