From 302b18833a0a1a439c88f2ca397eb1b3ad968ad1 Mon Sep 17 00:00:00 2001 From: cora Date: Wed, 26 Oct 2022 04:05:24 +0200 Subject: [PATCH] Add variable interior for nether bulwark --- mods/MAPGEN/mcl_nether_fortresses/init.lua | 11 +++++++++-- ...ther_fortresses_nether_bulwark_interior_2.mts | Bin 0 -> 1170 bytes ...ther_fortresses_nether_bulwark_interior_3.mts | Bin 0 -> 757 bytes ...ther_fortresses_nether_bulwark_interior_4.mts | Bin 0 -> 882 bytes mods/MAPGEN/mcl_structures/api.lua | 7 +++---- 5 files changed, 12 insertions(+), 6 deletions(-) create mode 100644 mods/MAPGEN/mcl_nether_fortresses/schematics/mcl_nether_fortresses_nether_bulwark_interior_2.mts create mode 100644 mods/MAPGEN/mcl_nether_fortresses/schematics/mcl_nether_fortresses_nether_bulwark_interior_3.mts create mode 100644 mods/MAPGEN/mcl_nether_fortresses/schematics/mcl_nether_fortresses_nether_bulwark_interior_4.mts diff --git a/mods/MAPGEN/mcl_nether_fortresses/init.lua b/mods/MAPGEN/mcl_nether_fortresses/init.lua index 4375089ee5..57d9dbd8d1 100644 --- a/mods/MAPGEN/mcl_nether_fortresses/init.lua +++ b/mods/MAPGEN/mcl_nether_fortresses/init.lua @@ -36,8 +36,15 @@ mcl_structures.register_structure("nether_bulwark",{ filenames = { modpath.."/schematics/mcl_nether_fortresses_nether_bulwark.mts" }, - daughters = { - [modpath.."/schematics/mcl_nether_fortresses_nether_bulwark_interior_1.mts"] = vector.new(5,0,5), + daughters = {{ + files = { + modpath.."/schematics/mcl_nether_fortresses_nether_bulwark_interior_1.mts", + modpath.."/schematics/mcl_nether_fortresses_nether_bulwark_interior_2.mts", + modpath.."/schematics/mcl_nether_fortresses_nether_bulwark_interior_3.mts", + modpath.."/schematics/mcl_nether_fortresses_nether_bulwark_interior_4.mts", + }, + pos = vector.new(5,0,5), + }, }, y_offset = 0, construct_nodes = {"group:wall"}, diff --git a/mods/MAPGEN/mcl_nether_fortresses/schematics/mcl_nether_fortresses_nether_bulwark_interior_2.mts b/mods/MAPGEN/mcl_nether_fortresses/schematics/mcl_nether_fortresses_nether_bulwark_interior_2.mts new file mode 100644 index 0000000000000000000000000000000000000000..b73a5a59045f9c7b369c900114c32336099b7f1f GIT binary patch literal 1170 zcmeYb3HD`RVc=vCX5g&H1PlTU8o9|i@ku#}$=Ssv`FW{U2xfdzQD$;>d_jIrW^qPp z3IlUuW)XuZy7I*0#GDcaEs$_=2~b6`6_`RY65Sk0bR*!FGsvJzflZGu&dtv+$zae% zmxXJLPtM3JPR&V8LAX{I*+n^tNw^&pUy@(Iph>iH1~HJ*V)4Gl+x4Qu6bGL7iEYp9f~f zC&e3LmnZ>Bs36-5iX`N~fW>dcoVQ`OgIWxDcyDv-togO*@$+A=FJb|l%=V8TD zu*}on&q>o^i(+5O^gm(8mU4ThU1L0J5mq@<&FLqPX-7{ylD z-LD+pRlIld(G?Rke@(x-C!jRCcgwpu?iu}> z)M6*KgX$r!-y?2F>fE{3s2!AYisLD-Pw@QojL@GGYP@Qlk8NuE^!xU@mD%r{tNbrk z^KjS(TsBxx=5#2phgm7}|B^zVxxywalRO<(aIMfk+x=eP_pEL1uLN&u|F+w*toTiD z_OXk>O3AJ%zM1R$Tp}9$EIoqY>Q~X!TKHY4u!LP5Bv-(u^ z;*zVufBXvXF`Z|c`Cw_8VlVU6#r=*eMY5Lu{Bm3~oB85_?!P~76zKT9zwb4Vaa(n1 z7)O@Vd4|NlD>n;&d63RI&$VJR*F;HCyA`gFnoBK%6#d`ryS)5;%=Ql1H%|B54}4B^ zT9!YLKf0#r?jx=jtUn)d9Md$8s(g8Q)3aoT^Q$FRJ74X;>}UOU%jJKoP3uzrhSf*C z_nmU1nz?!cZ?F26>-Uu}CF-`-t4eLXR@r|0bzbY=+^y|vezUIDEztkvzb0>+eBW#( wlZ>u%&-cC(R}SCa$Z+bv;kMPUmZpDX{_Vi?_d!eD6_e|C`#%fsm*Z3h01bHx#{d8T literal 0 HcmV?d00001 diff --git a/mods/MAPGEN/mcl_nether_fortresses/schematics/mcl_nether_fortresses_nether_bulwark_interior_3.mts b/mods/MAPGEN/mcl_nether_fortresses/schematics/mcl_nether_fortresses_nether_bulwark_interior_3.mts new file mode 100644 index 0000000000000000000000000000000000000000..0a4c054254075f04b8392e100db5364b6e180251 GIT binary patch literal 757 zcmeYb3HD`RVc=vCX5g&H1Pt5^8o9|i@ku#}$=Ssv`FW{U2xfdzQD$;>d_jIrW^qPp z3IlUuW)XuJNO^KbYH>-i6_|=I&P~k8VbI2HOmaqMacWL#3c@5Abj69qi8&=elk)RR zG8iP$W#Nuv5Ji^)Yh=&@2^W_D-B)Y{rjR^@?h7e2Bl1#9GE$4;)AMsu7=%D_$@xX8 zRv>OtPJVJWg9<*gVPR7-=WRrGaf<>^49k}5@Bi-o`#LmRh4HZDyTJ5QY3JBaOj@I8 z!7fs;`r^(siyhN+%DfkwE<1Q+^6{&WCK`WckZb(AWYtBJ`iTBI>+Q!Ll&{+m`~OzP zGtL>$I8tKDyl+`N^soKaz`razd!3r>p_eM3(s@v(BNAB<(1R86pE*cbk1x$y*I{w{u{Y9?*#gD*IPfz3~s7e zQ|&Xi{rc7F`%LH8t>){0yYrU$$;CErS51zl literal 0 HcmV?d00001 diff --git a/mods/MAPGEN/mcl_nether_fortresses/schematics/mcl_nether_fortresses_nether_bulwark_interior_4.mts b/mods/MAPGEN/mcl_nether_fortresses/schematics/mcl_nether_fortresses_nether_bulwark_interior_4.mts new file mode 100644 index 0000000000000000000000000000000000000000..d7e23f0278fb2b5b1765efc93ef726f9efa49c7a GIT binary patch literal 882 zcmeYb3HD`RVc=vCX5g&H1Pr_k8o9|i@ku#}$=Ssv`FW{U2xfdzQD$;>d_jIrW^qPp z3WFq0l?=>@nMDlRIOXG$Gct=)b5c_fhRL8SPApE$DTy!6&Cf5%U=RYyCg&HWTBYab zq$K6!CucK=V$}f=1}n`;EK7_}%gHa#%u8nwftvspF3vA4N={`E1B+&)7MB!TC4(rS zg^4*i4B{a1l>GdnVyn!e{5&u-J}KT1yF>|4LItFwxCH3$Vk%Z-({>sS3DAXGC_NJxjmZ@%>_VW#uST-(PEi3PCcXfrQQFy$}s+rPD zkEs6K6=;=RBJ=#=qn6^QD|GpLAMZJ~z2=w{?<)4B!yFE7Or6ZGb1qi7)yw>yIQ#FU zv-ZKI>GPI)J^m7?``E+3B;v-S6O~^kWO#HIR4F{ZHEXqrA9twU@h$4Vt@!lygZ93yhi>hkUe#@~Oy%~swW}vR$?^;pS{AhB+SQVCzixAV{=0Qo)z^Ph zvOeq(Jn?f!jOmhfR#M9%icfCYw(gIf%F>U!Rt-e#L!7^JtF Hzr0fbh$EME literal 0 HcmV?d00001 diff --git a/mods/MAPGEN/mcl_structures/api.lua b/mods/MAPGEN/mcl_structures/api.lua index d1be83015a..efbe3ccb14 100644 --- a/mods/MAPGEN/mcl_structures/api.lua +++ b/mods/MAPGEN/mcl_structures/api.lua @@ -266,16 +266,15 @@ function mcl_structures.place_structure(pos, def, pr, blockseed) local ap = function(pos,def,pr,blockseed) end if def.daughters then - for fn,p in pairs(def.daughters) do - local p = vector.add(pp,p) + for _,d in pairs(def.daughters) do + local p = vector.add(pp,d.pos) ap = function(pos,def,pr,blockseed) - mcl_structures.place_schematic(pos, fn, rot, nil, true, "place_center_x,place_center_z",function() + mcl_structures.place_schematic(pos, d.files[pr:next(1,#d.files)], rot, nil, true, "place_center_x,place_center_z",function() if def.loot then generate_loot(pp,def,pr,blockseed) end if def.construct_nodes then construct_nodes(pp,def,pr,blockseed) end if def.after_place then def.after_place(pos,def,pr) end - --ap(pos,def,pr,blockseed) end,pr) end end