From 9f6d90aa811dd8f523b137d602127d31307ea15c Mon Sep 17 00:00:00 2001 From: Paramat Date: Sun, 3 Sep 2017 21:32:21 +0100 Subject: Ores: Add stratum ore (#6352) Creates a single undulating ore stratum that is continuous across mapchunk borders and horizontally spans the world. Due to being continuous is ideal for creating bands of alternative stone type running through cliffs and mountains, or underground layers. Add missing documentation of 'ore_param2' parameter. --- src/script/lua_api/l_mapgen.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src/script') diff --git a/src/script/lua_api/l_mapgen.cpp b/src/script/lua_api/l_mapgen.cpp index 0875e2c95..c2b256228 100644 --- a/src/script/lua_api/l_mapgen.cpp +++ b/src/script/lua_api/l_mapgen.cpp @@ -73,6 +73,7 @@ struct EnumString ModApiMapgen::es_OreType[] = {ORE_PUFF, "puff"}, {ORE_BLOB, "blob"}, {ORE_VEIN, "vein"}, + {ORE_STRATUM, "stratum"}, {0, NULL}, }; @@ -1149,6 +1150,15 @@ int ModApiMapgen::l_register_ore(lua_State *L) break; } + case ORE_STRATUM: { + OreStratum *orestratum = (OreStratum *)ore; + + lua_getfield(L, index, "np_stratum_thickness"); + read_noiseparams(L, -1, &orestratum->np_stratum_thickness); + lua_pop(L, 1); + + break; + } default: break; } -- cgit v1.2.3