aboutsummaryrefslogtreecommitdiff
path: root/src/mapgen_v5.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/mapgen_v5.cpp')
-rw-r--r--src/mapgen_v5.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mapgen_v5.cpp b/src/mapgen_v5.cpp
index afe34164c..e98b211af 100644
--- a/src/mapgen_v5.cpp
+++ b/src/mapgen_v5.cpp
@@ -412,11 +412,11 @@ void MapgenV5::generateBiomes() {
for (s16 y = node_max.Y; y >= node_min.Y; y--) {
content_t c = vm->m_data[i].getContent();
- if ((c == c_stone || c == c_dirt_with_grass
- || c == c_dirt
- || c == c_sand
- || c == c_lava_source
- || c == c_gravel) && have_air) {
+ bool is_replaceable_content =
+ c == c_stone || c == c_dirt_with_grass || c == c_dirt ||
+ c == c_sand || c == c_lava_source || c == c_gravel;
+
+ if (is_replaceable_content && have_air) {
content_t c_below = vm->m_data[i - em.X].getContent();
if (c_below != CONTENT_AIR) {