1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-08-11 17:51:04 +00:00

Dungeons: Settable density noise, move number calculation to mapgens (#8473)

Add user-settable noise parameters for dungeon density to each mapgen,
except V6 which hardcodes this noise parameter.

Move the calculation of number of dungeons generated in a mapchunk out
of dungeongen.cpp and into mapgen code, to allow mapgens to generate
any desired number of dungeons in a mapchunk, instead of being forced
to have number of dungeons determined by a density noise.

This is more flexible and allows mapgens to use dungeon generation to
create custom structures, such as occasional mega-dungeons.
This commit is contained in:
Paramat 2019-06-01 20:50:43 +01:00 committed by GitHub
parent a1459a9eac
commit 7379aa74cf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 154 additions and 95 deletions

View file

@ -48,6 +48,7 @@ struct MapgenFlatParams : public MapgenParams
NoiseParams np_filler_depth;
NoiseParams np_cave1;
NoiseParams np_cave2;
NoiseParams np_dungeons;
MapgenFlatParams();
~MapgenFlatParams() = default;