diff options
author | paramat <paramat@users.noreply.github.com> | 2017-07-28 03:31:11 +0100 |
---|---|---|
committer | paramat <mat.gregory@virginmedia.com> | 2017-07-30 18:40:55 +0100 |
commit | b20d01a3f19ea7ad1e788077af1ed5769648e3a1 (patch) | |
tree | 2d30ee6e8771bfddeb5140e4304e03795ef81190 /src/mapgen_valleys.cpp | |
parent | 238d752fa3021fa7294a4df79bfa0b8a46f4a018 (diff) | |
download | minetest-b20d01a3f19ea7ad1e788077af1ed5769648e3a1.tar.gz minetest-b20d01a3f19ea7ad1e788077af1ed5769648e3a1.tar.bz2 minetest-b20d01a3f19ea7ad1e788077af1ed5769648e3a1.zip |
Dungeons: Use biome 'node_stone' if normal stone types not detected
Construct dungeons from the node defined as biome 'node_stone' if
'mapgen_stone', 'mapgen_desert_stone' and 'mapgen_sandstone' are not
detected.
Feature long-intended by kwolekr/hmmmm and present in code as a TODO.
Diffstat (limited to 'src/mapgen_valleys.cpp')
-rw-r--r-- | src/mapgen_valleys.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mapgen_valleys.cpp b/src/mapgen_valleys.cpp index ff56c69da..f0c145934 100644 --- a/src/mapgen_valleys.cpp +++ b/src/mapgen_valleys.cpp @@ -236,7 +236,9 @@ void MapgenValleys::makeChunk(BlockMakeData *data) updateHeightmap(node_min, node_max); // Place biome-specific nodes and build biomemap - MgStoneType stone_type = generateBiomes(water_level - 1); + MgStoneType mgstone_type; + content_t biome_stone; + generateBiomes(&mgstone_type, &biome_stone, water_level - 1); // Cave creation. if (flags & MG_CAVES) @@ -244,7 +246,7 @@ void MapgenValleys::makeChunk(BlockMakeData *data) // Dungeon creation if ((flags & MG_DUNGEONS) && node_max.Y < 50) - generateDungeons(stone_surface_max_y, stone_type); + generateDungeons(stone_surface_max_y, mgstone_type, biome_stone); // Generate the registered decorations if (flags & MG_DECORATIONS) |