From 72847c3d4be1f297f03ad9b19ed13ddd213c5be0 Mon Sep 17 00:00:00 2001 From: kno10 Date: Thu, 31 Oct 2024 00:53:33 +0100 Subject: [PATCH] tweak structure parameters --- mods/MAPGEN/mcl_structures/pillager_outpost.lua | 8 +++++--- mods/MAPGEN/mcl_structures/shipwrecks.lua | 4 ++-- mods/MAPGEN/mcl_structures/woodland_mansion.lua | 2 +- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/mods/MAPGEN/mcl_structures/pillager_outpost.lua b/mods/MAPGEN/mcl_structures/pillager_outpost.lua index b310b33b4..71c12b09a 100644 --- a/mods/MAPGEN/mcl_structures/pillager_outpost.lua +++ b/mods/MAPGEN/mcl_structures/pillager_outpost.lua @@ -6,7 +6,7 @@ local spawnon = {"mcl_core:stripped_oak","mcl_stairs:slab_birchwood_top"} vl_structures.register_structure("pillager_outpost",{ place_on = {"group:grass_block","group:dirt","mcl_core:dirt_with_grass","group:sand"}, flags = "place_center_x, place_center_z", - prepare = { padding = 3, corners = 4, foundation = -8, clear = true }, + prepare = { tolerance = 4, padding = 3, corners = 4, foundation = -8, clear = true }, y_offset = 0, chunk_probability = 15, y_max = mcl_vars.mg_overworld_max, @@ -57,8 +57,10 @@ vl_structures.register_structure("pillager_outpost",{ } }} }, - after_place = function(p,_,pr) -- fixme: use p1, p2 from the callback? - local p1, p2 = vector.offset(p,-9,0,-9), vector.offset(p,9,32,9) + after_place = function(p,_,pr,p1,p2) + for _,n in pairs(minetest.find_nodes_in_area(p1,p2,{"group:wall"})) do + mcl_walls.update_wall(n) + end vl_structures.spawn_mobs("mobs_mc:pillager",spawnon,p1,p2,pr,5) vl_structures.spawn_mobs("mobs_mc:parrot",{"mesecons_pressureplates:pressure_plate_stone_off"},p1,p2,pr,3) vl_structures.spawn_mobs("mobs_mc:iron_golem",{"mesecons_button:button_stone_off"},p1,p2,pr,1) diff --git a/mods/MAPGEN/mcl_structures/shipwrecks.lua b/mods/MAPGEN/mcl_structures/shipwrecks.lua index c7eb279d9..970bcf299 100644 --- a/mods/MAPGEN/mcl_structures/shipwrecks.lua +++ b/mods/MAPGEN/mcl_structures/shipwrecks.lua @@ -71,10 +71,10 @@ vl_structures.register_structure("shipwreck",{ place_on = {"group:sand","mcl_core:gravel"}, spawn_by = {"group:water"}, num_spawn_by = 4, - chunk_probability = 15, + chunk_probability = 20, biomes = ocean_biomes, y_min = mcl_vars.mg_overworld_min, - y_max = water_level-4, + y_max = water_level-5, y_offset = function(pr) return pr:next(-3,-1) end, flags = "place_center_x, place_center_z, force_placement", prepare = { tolerance = -1, clear = false, foundation = false, mode = "water" }, diff --git a/mods/MAPGEN/mcl_structures/woodland_mansion.lua b/mods/MAPGEN/mcl_structures/woodland_mansion.lua index 3d735eae2..22b1b8505 100644 --- a/mods/MAPGEN/mcl_structures/woodland_mansion.lua +++ b/mods/MAPGEN/mcl_structures/woodland_mansion.lua @@ -6,7 +6,7 @@ local spawnon = {"mcl_deepslate:deepslate","mcl_core:birchwood","mcl_wool:red_ca vl_structures.register_structure("woodland_cabin",{ place_on = {"group:grass_block","group:dirt","mcl_core:dirt_with_grass"}, flags = "place_center_x, place_center_z", - prepare = { padding = 2, corners = 5, foundation = true, clear = true, clear_top = 2 }, + prepare = { tolerance = 3, padding = 2, corners = 5, foundation = -5, clear = true, clear_top = 2 }, force_placement = false, chunk_probability = 20, y_max = mcl_vars.mg_overworld_max,