Skip to content

Commit 4682c7b

Browse files
authoredSep 8, 2019
Dungeons: Remove non-functional 'projecting dungeons' setting (#8897)
1 parent e97cbcf commit 4682c7b

File tree

3 files changed

+5
-11
lines changed

3 files changed

+5
-11
lines changed
 

‎builtin/settingtypes.txt

-3
Original file line numberDiff line numberDiff line change
@@ -1384,9 +1384,6 @@ mapgen_limit (Map generation limit) int 31000 0 31000
13841384
# and junglegrass, in all other mapgens this flag controls all decorations.
13851385
mg_flags (Mapgen flags) flags caves,dungeons,light,decorations,biomes caves,dungeons,light,decorations,biomes,nocaves,nodungeons,nolight,nodecorations,nobiomes
13861386

1387-
# Whether dungeons occasionally project from the terrain.
1388-
projecting_dungeons (Projecting dungeons) bool true
1389-
13901387
[*Biome API temperature and humidity noise parameters]
13911388

13921389
# Temperature variation for biomes.

‎src/defaultsettings.cpp

-1
Original file line numberDiff line numberDiff line change
@@ -421,7 +421,6 @@ void set_default_settings(Settings *settings)
421421
settings->setDefault("mg_flags", "caves,dungeons,light,decorations,biomes");
422422
settings->setDefault("fixed_map_seed", "");
423423
settings->setDefault("max_block_generate_distance", "8");
424-
settings->setDefault("projecting_dungeons", "true");
425424
settings->setDefault("enable_mapgen_debug_info", "false");
426425

427426
// Server list announcing

‎src/mapgen/dungeongen.cpp

+5-7
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,6 @@ void DungeonGen::generate(MMVManip *vm, u32 bseed, v3s16 nmin, v3s16 nmax)
8686

8787
//TimeTaker t("gen dungeons");
8888

89-
static const bool preserve_ignore = !g_settings->getBool("projecting_dungeons");
90-
9189
this->vm = vm;
9290
this->blockseed = bseed;
9391
random.seed(bseed + 2);
@@ -96,9 +94,10 @@ void DungeonGen::generate(MMVManip *vm, u32 bseed, v3s16 nmin, v3s16 nmax)
9694
vm->clearFlag(VMANIP_FLAG_DUNGEON_INSIDE | VMANIP_FLAG_DUNGEON_PRESERVE);
9795

9896
if (dp.only_in_ground) {
99-
// Set all air and liquid drawtypes to be untouchable to make dungeons
100-
// open to air and liquids.
101-
// Optionally set ignore to be untouchable to prevent projecting dungeons.
97+
// Set all air and liquid drawtypes to be untouchable to make dungeons generate
98+
// in ground only.
99+
// Set 'ignore' to be untouchable to prevent generation in ungenerated neighbor
100+
// mapchunks, to avoid dungeon rooms generating outside ground.
102101
// Like randomwalk caves, preserve nodes that have 'is_ground_content = false',
103102
// to avoid dungeons that generate out beyond the edge of a mapchunk destroying
104103
// nodes added by mods in 'register_on_generated()'.
@@ -109,8 +108,7 @@ void DungeonGen::generate(MMVManip *vm, u32 bseed, v3s16 nmin, v3s16 nmax)
109108
content_t c = vm->m_data[i].getContent();
110109
NodeDrawType dtype = ndef->get(c).drawtype;
111110
if (dtype == NDT_AIRLIKE || dtype == NDT_LIQUID ||
112-
(preserve_ignore && c == CONTENT_IGNORE) ||
113-
!ndef->get(c).is_ground_content)
111+
c == CONTENT_IGNORE || !ndef->get(c).is_ground_content)
114112
vm->m_flags[i] |= VMANIP_FLAG_DUNGEON_PRESERVE;
115113
i++;
116114
}

0 commit comments

Comments
 (0)
Please sign in to comment.