aboutsummaryrefslogtreecommitdiff
path: root/src/emerge.cpp
diff options
context:
space:
mode:
authorkwolekr <kwolekr@minetest.net>2014-12-09 00:37:48 -0500
committerkwolekr <kwolekr@minetest.net>2014-12-09 00:38:04 -0500
commit29b413b376d42c27bf1f7065c9f7c850b61f3f24 (patch)
treef5cc0ca2d4306cb63094b794540668f611cf4ff4 /src/emerge.cpp
parent74903689848bcd277329f3bd54c62f2aa8306f40 (diff)
downloadminetest-29b413b376d42c27bf1f7065c9f7c850b61f3f24.tar.gz
minetest-29b413b376d42c27bf1f7065c9f7c850b61f3f24.tar.bz2
minetest-29b413b376d42c27bf1f7065c9f7c850b61f3f24.zip
Biomes: Make biome heat and humidity noise parameters user-configurable
Diffstat (limited to 'src/emerge.cpp')
-rw-r--r--src/emerge.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/emerge.cpp b/src/emerge.cpp
index 8813a71a9..133fd4a59 100644
--- a/src/emerge.cpp
+++ b/src/emerge.cpp
@@ -363,6 +363,8 @@ void EmergeManager::loadParamsFromSettings(Settings *settings) {
settings->getS16NoEx("water_level", params.water_level);
settings->getS16NoEx("chunksize", params.chunksize);
settings->getFlagStrNoEx("mg_flags", params.flags, flagdesc_mapgen);
+ settings->getNoiseParams("mg_biome_np_heat", params.np_biome_heat);
+ settings->getNoiseParams("mg_biome_np_humidity", params.np_biome_humidity);
delete params.sparams;
params.sparams = createMapgenParams(params.mg_name);
@@ -377,6 +379,8 @@ void EmergeManager::saveParamsToSettings(Settings *settings) {
settings->setS16("water_level", params.water_level);
settings->setS16("chunksize", params.chunksize);
settings->setFlagStr("mg_flags", params.flags, flagdesc_mapgen, (u32)-1);
+ settings->setNoiseParams("mg_biome_np_heat", params.np_biome_heat);
+ settings->setNoiseParams("mg_biome_np_humidity", params.np_biome_humidity);
if (params.sparams)
params.sparams->writeParams(settings);