aboutsummaryrefslogtreecommitdiff
path: root/src/script/lua_api/l_mapgen.h
diff options
context:
space:
mode:
authorkwolekr <kwolekr@minetest.net>2016-06-24 18:15:56 -0400
committerkwolekr <kwolekr@minetest.net>2016-07-03 15:38:36 -0400
commit3c63c3044d5e4ca36c2649c530f31622581d90fd (patch)
treeb7924100f14f5626c11d534e2ad3602e269ac1df /src/script/lua_api/l_mapgen.h
parent92705306bfb4994107a43514f29997cea15d48dc (diff)
downloadminetest-3c63c3044d5e4ca36c2649c530f31622581d90fd.tar.gz
minetest-3c63c3044d5e4ca36c2649c530f31622581d90fd.tar.bz2
minetest-3c63c3044d5e4ca36c2649c530f31622581d90fd.zip
Add MapSettingsManager and new mapgen setting script API functions
This commit refactors the majority of the Mapgen settings system. - MapgenParams is now owned by MapSettingsManager, itself a part of ServerMap, instead of the EmergeManager. - New Script API functions added: core.get_mapgen_setting core.get_mapgen_setting_noiseparams, core.set_mapgen_setting, and core.set_mapgen_setting_noiseparams. - minetest.get/set_mapgen_params are deprecated by the above new functions. - It is now possible to view and modify any arbitrary mapgen setting from a mod, rather than the base MapgenParams structure. - MapgenSpecificParams has been removed.
Diffstat (limited to 'src/script/lua_api/l_mapgen.h')
-rw-r--r--src/script/lua_api/l_mapgen.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/script/lua_api/l_mapgen.h b/src/script/lua_api/l_mapgen.h
index 9751c0db6..bb94575c7 100644
--- a/src/script/lua_api/l_mapgen.h
+++ b/src/script/lua_api/l_mapgen.h
@@ -40,6 +40,18 @@ private:
// set mapgen parameters
static int l_set_mapgen_params(lua_State *L);
+ // get_mapgen_setting(name)
+ static int l_get_mapgen_setting(lua_State *L);
+
+ // set_mapgen_setting(name, value, override_meta)
+ static int l_set_mapgen_setting(lua_State *L);
+
+ // get_mapgen_setting_noiseparams(name)
+ static int l_get_mapgen_setting_noiseparams(lua_State *L);
+
+ // set_mapgen_setting_noiseparams(name, value, override_meta)
+ static int l_set_mapgen_setting_noiseparams(lua_State *L);
+
// set_noiseparam_defaults(name, noiseparams, set_default)
static int l_set_noiseparams(lua_State *L);