From 524de7d3022600c6a122769b96e2ba7c3c3df0bf Mon Sep 17 00:00:00 2001 From: Vanessa Ezekowitz Date: Thu, 23 Feb 2017 10:13:05 -0500 Subject: [PATCH] if moreblocks is installed, don't register the three separate "roof" items rather, alias them to the equivalents in moreblocks instead. don't register cottages straw or wool anymore, alias them to farming straw and white wool. --- depends.txt | 2 +- init.lua | 10 +++++++++- nodes_historic.lua | 14 +------------- nodes_roof.lua | 6 +++--- nodes_straw.lua | 18 +++++------------- textures/cottages_darkage_straw.png | Bin 852 -> 0 bytes textures/cottages_wool.png | Bin 306 -> 0 bytes 7 files changed, 19 insertions(+), 31 deletions(-) delete mode 100644 textures/cottages_darkage_straw.png delete mode 100644 textures/cottages_wool.png diff --git a/depends.txt b/depends.txt index e10338b..2e15492 100644 --- a/depends.txt +++ b/depends.txt @@ -1,8 +1,8 @@ default? farming +wool stairs? homedecor? intllib? trees? -wool? moreblocks? diff --git a/init.lua b/init.lua index cbafc0a..2e23660 100644 --- a/init.lua +++ b/init.lua @@ -61,7 +61,15 @@ dofile(minetest.get_modpath("cottages").."/nodes_straw.lua"); dofile(minetest.get_modpath("cottages").."/nodes_anvil.lua"); dofile(minetest.get_modpath("cottages").."/nodes_doorlike.lua"); dofile(minetest.get_modpath("cottages").."/nodes_fences.lua"); -dofile(minetest.get_modpath("cottages").."/nodes_roof.lua"); + +if not minetest.get_modpath("moreblocks") then + dofile(minetest.get_modpath("cottages").."/nodes_roof.lua"); +else + minetest.register_alias("cottages:roof_straw", "moreblocks:stair_straw_alt") + minetest.register_alias("cottages:roof_connector_straw", "moreblocks:stair_straw") + minetest.register_alias("cottages:roof_flat_straw", "moreblocks:slab_straw") +end + dofile(minetest.get_modpath("cottages").."/nodes_barrel.lua"); --dofile(minetest.get_modpath("cottages").."/nodes_chests.lua"); diff --git a/nodes_historic.lua b/nodes_historic.lua index 1fa5ea4..2f84d26 100644 --- a/nodes_historic.lua +++ b/nodes_historic.lua @@ -179,13 +179,8 @@ minetest.register_node("cottages:wool_tent", { }) -- a fallback for cases in which there is no wool -minetest.register_node("cottages:wool", { - description = "Wool", - tiles = {"cottages_wool.png"}, - is_ground_content = false, - groups = {snappy=2,choppy=2,oddly_breakable_by_hand=3,flammable=3,wool=1}, -}) +minetest.register_alias("cottages:wool", "wool:white") --------------------------------------------------------------------------------------- -- crafting receipes @@ -263,10 +258,3 @@ minetest.register_craft({ {"",cottages.craftitem_stick} } }) - -minetest.register_craft({ - output = "cottages:wool", - recipe = { - {"cottages:wool_tent", "cottages:wool_tent"} - } -}) diff --git a/nodes_roof.lua b/nodes_roof.lua index 11174d8..d130348 100644 --- a/nodes_roof.lua +++ b/nodes_roof.lua @@ -147,9 +147,9 @@ end -- of cottages.register_roof( name, tiles, basic_material ) -- add the diffrent roof types --------------------------------------------------------------------------------------- cottages.register_roof( 'straw', - {"cottages_darkage_straw.png","cottages_darkage_straw.png", - "cottages_darkage_straw.png","cottages_darkage_straw.png", - "cottages_darkage_straw.png","cottages_darkage_straw.png"}, + {"farming_straw.png","farming_straw.png", + "farming_straw.png","farming_straw.png", + "farming_straw.png","farming_straw.png"}, 'cottages:straw_mat', nil ); cottages.register_roof( 'reet', {"cottages_reet.png","cottages_reet.png", diff --git a/nodes_straw.lua b/nodes_straw.lua index a26b728..e92402b 100644 --- a/nodes_straw.lua +++ b/nodes_straw.lua @@ -24,9 +24,9 @@ end minetest.register_node("cottages:straw_mat", { description = S("layer of straw"), drawtype = 'nodebox', - tiles = { 'cottages_darkage_straw.png' }, -- done by VanessaE - wield_image = 'cottages_darkage_straw.png', - inventory_image = 'cottages_darkage_straw.png', + tiles = { 'farming_straw.png' }, -- done by VanessaE + wield_image = 'farming_straw.png', + inventory_image = 'farming_straw.png', sunlight_propagates = true, paramtype = 'light', paramtype2 = "facedir", @@ -76,16 +76,8 @@ minetest.register_node("cottages:straw_bale", { }) -- just straw -minetest.register_node("cottages:straw", { - drawtype = "normal", - description = S("straw"), - tiles = {"cottages_darkage_straw.png"}, - groups = {snappy=3,choppy=3,oddly_breakable_by_hand=3,flammable=3}, - sounds = default.node_sound_wood_defaults(), - -- the bale is slightly smaller than a full node - is_ground_content = false, -}) +minetest.register_alias("cottages:straw", "farming:straw") local cottages_formspec_treshing_floor = "size[8,8]".. @@ -243,7 +235,7 @@ minetest.register_node("cottages:threshing_floor", { end local overlay1 = "^farming_wheat.png"; - local overlay2 = "^cottages_darkage_straw.png"; + local overlay2 = "^farming_straw.png"; local overlay3 = "^"..cottages.texture_wheat_seed; -- this can be enlarged by a multiplicator if desired diff --git a/textures/cottages_darkage_straw.png b/textures/cottages_darkage_straw.png deleted file mode 100644 index 9817316a37bb59866e4b904a6cf0617d2b85a3b8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 852 zcmV-a1FQUrP)Px#32;bRa{vGf6951U69E94oEQKA00(qQO+^RX3Jwk}5ko^xaR2}U=1D|BR5;58 z!P#ybRRDnD|C~8zRxjh&<4Ga7O%(~E3Kc52EQIawxDnicO)!?r!{d&!ERjk`wwr?U z&zJPWfYx|OB+6}Y1Dky1;R|^EQ$(KhDfShkFd$8A;%JEc?!-b?HizSo!1WmTE=R`- zSG%12(4*}}B)f+3RP*Xhz;+{<#EN7G+iin1#^CiFaHmXSShA8S7PXvKiV>z19q{9+9 zwr%t3M~w`JlD;o67?dM<^UF7cfkOC#Jnd*&@IA@>O~E+w2yD&qaYr<*$XJUvCXEekRziZH`YpF2A%qTy{jU!0|ONPeb-Q!})(L zMOKkK*_c|fTp8j+O`3w7J_9KlCL_h-I%oOV5RV0cXE7WG1ffN}Z_%RVaAuS31i}({ zp2v%0g?#t6Af5^=OHfxiN6%f}{ZmlZf~INs^=HlUu_4VG;zP}c_a)nVgAfAOH>kF1 z8H9??ve+zZd=Hums=T4e4F|CzOH;C)#MB1cS16rQl!hV$`IHJkQKWnJh0QiG6lufF zRYBf#RE>)pzEW>J@Ju7X)RclEz7Hfbm!7rmDm=PdCOvv;rB}FswC)@q=~|b94y^& ecbm}fQI&tCul0INwvK~xyi6^%y@1VIP`O=#$xX7>MIUFKk6AypYH_vZ5$ zXRX7nfqgA5L?cgP5TQ>;Cq$J)R0LHa_i3Uv`&Dj;=;