diff options
author | paramat <paramat@users.noreply.github.com> | 2017-06-14 02:00:51 +0100 |
---|---|---|
committer | paramat <mat.gregory@virginmedia.com> | 2017-07-11 01:14:24 +0100 |
commit | 8299e4b67eff48e0f6e101afea2fae8f0e65c421 (patch) | |
tree | fed891f09468aca2b53c8ced933fb88de2a823c6 /src/mg_decoration.h | |
parent | ef285b2815962a7a01791059ed984cb12fdba4dd (diff) | |
download | minetest-8299e4b67eff48e0f6e101afea2fae8f0e65c421.tar.gz minetest-8299e4b67eff48e0f6e101afea2fae8f0e65c421.tar.bz2 minetest-8299e4b67eff48e0f6e101afea2fae8f0e65c421.zip |
Biomes/decorations/ores: Make relative to 'water_level' setting
Add 'biome_zero_level' argument to 'generateBiomes()', 'deco_zero_level'
argument to 'placeAllDecos()' and 'ore_zero_level' to 'placeAllOres()'
to allow mapgens to vertically shift the registered biomes, decorations
and ores per-mapchunk.
Will also allow many realm possibilities in future mapgens.
Diffstat (limited to 'src/mg_decoration.h')
-rw-r--r-- | src/mg_decoration.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/mg_decoration.h b/src/mg_decoration.h index 968c78612..a7fdb97fe 100644 --- a/src/mg_decoration.h +++ b/src/mg_decoration.h @@ -70,7 +70,8 @@ public: virtual void resolveNodeNames(); bool canPlaceDecoration(MMVManip *vm, v3s16 p); - size_t placeDeco(Mapgen *mg, u32 blockseed, v3s16 nmin, v3s16 nmax); + size_t placeDeco(Mapgen *mg, u32 blockseed, + v3s16 nmin, v3s16 nmax, s16 deco_zero_level); //size_t placeCutoffs(Mapgen *mg, u32 blockseed, v3s16 nmin, v3s16 nmax); virtual size_t generate(MMVManip *vm, PcgRandom *pr, v3s16 p) = 0; @@ -145,7 +146,8 @@ public: } } - size_t placeAllDecos(Mapgen *mg, u32 blockseed, v3s16 nmin, v3s16 nmax); + size_t placeAllDecos(Mapgen *mg, u32 blockseed, + v3s16 nmin, v3s16 nmax, s16 deco_zero_level = 0); }; #endif |