floatland - only works with mg7 cos floatlands

This commit is contained in:
mckaygerhard 2023-06-22 22:19:17 -04:00
parent b00fbc98e7
commit e2116ce5c6

View File

@ -1,6 +1,7 @@
-- minetest.clear_registered_biomes() -- do not regenerate, we want to combine it! -- minetest.clear_registered_biomes() -- do not regenerate, we want to combine it!
-- Get setting or default -- Get setting or default
local mgv = minetest.get_mapgen_setting("mg_name") or nil
local mgv7_spflags = minetest.get_mapgen_setting("mgv7_spflags") or "mountains, ridges, floatlands, caverns" local mgv7_spflags = minetest.get_mapgen_setting("mgv7_spflags") or "mountains, ridges, floatlands, caverns"
local captures_float = string.match(mgv7_spflags, "floatlands") local captures_float = string.match(mgv7_spflags, "floatlands")
local captures_nofloat = string.match(mgv7_spflags, "nofloatlands") local captures_nofloat = string.match(mgv7_spflags, "nofloatlands")
@ -14,7 +15,7 @@ default.mgv7_floatland_level = floatland_y
default.mgv7_shadow_limit = minetest.get_mapgen_setting("mgv7_shadow_limit") or 1024 default.mgv7_shadow_limit = minetest.get_mapgen_setting("mgv7_shadow_limit") or 1024
-- Registering of the nodes -- Registering of the nodes
if mgv7 then
minetest.register_node("floatland:grass", { minetest.register_node("floatland:grass", {
description = "High Grass", description = "High Grass",
tiles = {"floatland_realm_grass.png", "floatland_realm_dirt.png", tiles = {"floatland_realm_grass.png", "floatland_realm_dirt.png",
@ -151,3 +152,4 @@ minetest.register_decoration({
y_max = worldlimit, y_max = worldlimit,
decoration = "default:bush_sapling", decoration = "default:bush_sapling",
}) })
end