aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorvlapsley <vaughan.lapsley@gmail.com>2017-07-07 13:49:55 +1000
committerparamat <mat.gregory@virginmedia.com>2017-07-07 22:28:40 +0100
commitf871852f13db6072b3bffe25826d7520ef031ec0 (patch)
treec33bf51e7163b883372e2ce27a9c62aeb0e61481 /src
parent3caad3f3c9e319ca67d63231e8c64b2ace855fff (diff)
downloadminetest-f871852f13db6072b3bffe25826d7520ef031ec0.tar.gz
minetest-f871852f13db6072b3bffe25826d7520ef031ec0.tar.bz2
minetest-f871852f13db6072b3bffe25826d7520ef031ec0.zip
Mapgen Carpathian: Add lava_depth parameter
Diffstat (limited to 'src')
-rw-r--r--src/mapgen_carpathian.cpp3
-rw-r--r--src/mapgen_carpathian.h1
2 files changed, 4 insertions, 0 deletions
diff --git a/src/mapgen_carpathian.cpp b/src/mapgen_carpathian.cpp
index 8529fd55a..c33239087 100644
--- a/src/mapgen_carpathian.cpp
+++ b/src/mapgen_carpathian.cpp
@@ -57,6 +57,7 @@ MapgenCarpathian::MapgenCarpathian(
spflags = params->spflags;
cave_width = params->cave_width;
large_cave_depth = params->large_cave_depth;
+ lava_depth = params->lava_depth;
cavern_limit = params->cavern_limit;
cavern_taper = params->cavern_taper;
cavern_threshold = params->cavern_threshold;
@@ -131,6 +132,7 @@ void MapgenCarpathianParams::readParams(const Settings *settings)
settings->getFlagStrNoEx("mgcarpathian_spflags", spflags, flagdesc_mapgen_carpathian);
settings->getFloatNoEx("mgcarpathian_cave_width", cave_width);
settings->getS16NoEx("mgcarpathian_large_cave_depth", large_cave_depth);
+ settings->getS16NoEx("mgcarpathian_lava_depth", lava_depth);
settings->getS16NoEx("mgcarpathian_cavern_limit", cavern_limit);
settings->getS16NoEx("mgcarpathian_cavern_taper", cavern_taper);
settings->getFloatNoEx("mgcarpathian_cavern_threshold", cavern_threshold);
@@ -159,6 +161,7 @@ void MapgenCarpathianParams::writeParams(Settings *settings) const
settings->setFlagStr("mgcarpathian_spflags", spflags, flagdesc_mapgen_carpathian, U32_MAX);
settings->setFloat("mgcarpathian_cave_width", cave_width);
settings->setS16("mgcarpathian_large_cave_depth", large_cave_depth);
+ settings->setS16("mgcarpathian_lava_depth", lava_depth);
settings->setS16("mgcarpathian_cavern_limit", cavern_limit);
settings->setS16("mgcarpathian_cavern_taper", cavern_taper);
settings->setFloat("mgcarpathian_cavern_threshold", cavern_threshold);
diff --git a/src/mapgen_carpathian.h b/src/mapgen_carpathian.h
index 2dba409af..0dfb6fd2c 100644
--- a/src/mapgen_carpathian.h
+++ b/src/mapgen_carpathian.h
@@ -37,6 +37,7 @@ struct MapgenCarpathianParams : public MapgenParams
u32 spflags = MGCARPATHIAN_CAVERNS;
float cave_width = 0.09f;
s16 large_cave_depth = -33;
+ s16 lava_depth = -256;
s16 cavern_limit = -256;
s16 cavern_taper = 256;
float cavern_threshold = 0.7f;