mirror of
https://git.minetest.land/MineClone2/MineClone2.git
synced 2024-11-28 05:43:43 +01:00
Add lots of water lakes to mangrove swamps
This commit is contained in:
parent
b7f26e2ddc
commit
0bcbea4ce3
@ -29,7 +29,7 @@ local function airtower(pos,tbl,h)
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
local function makelake(pos,size,liquid,placein,border,pr)
|
local function makelake(pos,size,liquid,placein,border,pr,noair)
|
||||||
local node_under = minetest.get_node(vector.offset(pos,0,-1,0))
|
local node_under = minetest.get_node(vector.offset(pos,0,-1,0))
|
||||||
local p1 = vector.offset(pos,-size,-1,-size)
|
local p1 = vector.offset(pos,-size,-1,-size)
|
||||||
local p2 = vector.offset(pos,size,-1,size)
|
local p2 = vector.offset(pos,size,-1,size)
|
||||||
@ -70,7 +70,7 @@ local function makelake(pos,size,liquid,placein,border,pr)
|
|||||||
end
|
end
|
||||||
if border == nil or border == "mcl_core:dirt" then border = "mcl_core:dirt_with_grass" end
|
if border == nil or border == "mcl_core:dirt" then border = "mcl_core:dirt_with_grass" end
|
||||||
end
|
end
|
||||||
if an.name ~= liquid then
|
if not noair and an.name ~= liquid then
|
||||||
table.insert(br,pp)
|
table.insert(br,pp)
|
||||||
if un.name ~= liquid then
|
if un.name ~= liquid then
|
||||||
airtower(pp,air,55)
|
airtower(pp,air,55)
|
||||||
@ -209,6 +209,27 @@ mcl_structures.register_structure("water_lake",{
|
|||||||
end
|
end
|
||||||
})
|
})
|
||||||
|
|
||||||
|
mcl_structures.register_structure("water_lake_mangrove_swamp",{
|
||||||
|
place_on = {"mcl_mud:mud"},
|
||||||
|
biomes = { "MangroveSwamp" },
|
||||||
|
terrain_feature = true,
|
||||||
|
noise_params = {
|
||||||
|
offset = 0,
|
||||||
|
scale = 0.0032,
|
||||||
|
spread = {x = 250, y = 250, z = 250},
|
||||||
|
seed = 6343241353,
|
||||||
|
octaves = 3,
|
||||||
|
persist = 0.001,
|
||||||
|
flags = "absvalue",
|
||||||
|
},
|
||||||
|
flags = "place_center_x, place_center_z, force_placement",
|
||||||
|
y_max = mcl_vars.mg_overworld_max,
|
||||||
|
y_min = minetest.get_mapgen_setting("water_level"),
|
||||||
|
place_func = function(pos,def,pr)
|
||||||
|
return makelake(pos,3,"mcl_core:water_source",{"group:material_stone", "group:sand", "group:dirt","group:grass_block","mcl_mud:mud"},"mcl_mud:mud",pr,true)
|
||||||
|
end
|
||||||
|
})
|
||||||
|
|
||||||
local pool_adjacents = {
|
local pool_adjacents = {
|
||||||
vector.new(1,0,0),
|
vector.new(1,0,0),
|
||||||
vector.new(-1,0,0),
|
vector.new(-1,0,0),
|
||||||
|
Loading…
Reference in New Issue
Block a user