From 73f96ed5f303c1f27e59d36012b1457b86ebcf32 Mon Sep 17 00:00:00 2001 From: JoseDouglas26 Date: Sat, 4 May 2024 14:46:40 -0300 Subject: [PATCH] Bug fixes with recipes and some nodes --- mods/ITEMS/mcl_copper/crafting.lua | 8 +++----- mods/ITEMS/mcl_copper/nodes.lua | 23 ++++++++++++++++------- 2 files changed, 19 insertions(+), 12 deletions(-) diff --git a/mods/ITEMS/mcl_copper/crafting.lua b/mods/ITEMS/mcl_copper/crafting.lua index 66ea1d572..dadab82d3 100644 --- a/mods/ITEMS/mcl_copper/crafting.lua +++ b/mods/ITEMS/mcl_copper/crafting.lua @@ -90,8 +90,6 @@ end mcl_copper.register_variants_recipes("cut", "block", 4) mcl_copper.register_variants_recipes("grate", "block", 4) -mcl_copper.register_variants_recipes("door", "block", 3) -mcl_copper.register_variants_recipes("trapdoor", "block", 2) mcl_copper.register_variants_recipes("bulb_off", "block", 4) local chiseled_materials = { @@ -152,9 +150,9 @@ local cuttable_blocks = { for _, c in ipairs(cuttable_blocks) do mcl_stonecutter.register_recipe("mcl_copper:"..c, "mcl_copper:"..c.."_cut", 4) - mcl_stonecutter.register_recipe("mcl_copper:"..c, "mcl_copper:"..c:gsub("block", "grate"), 4) - mcl_stonecutter.register_recipe("mcl_copper:"..c, "mcl_copper:"..c:gsub("block", "chiseled"), 4) - mcl_stonecutter.register_recipe("mcl_copper:"..c.."_cut", "mcl_copper:"..c:gsub("block", "chiseled")) + --mcl_stonecutter.register_recipe("mcl_copper:"..c, "mcl_copper:"..c:gsub("block", "grate"), 4) + --mcl_stonecutter.register_recipe("mcl_copper:"..c, "mcl_copper:"..c:gsub("block", "chiseled"), 4) + --mcl_stonecutter.register_recipe("mcl_copper:"..c.."_cut", "mcl_copper:"..c:gsub("block", "chiseled")) end minetest.register_craft({ diff --git a/mods/ITEMS/mcl_copper/nodes.lua b/mods/ITEMS/mcl_copper/nodes.lua index b8a5c218c..f89ae57c7 100644 --- a/mods/ITEMS/mcl_copper/nodes.lua +++ b/mods/ITEMS/mcl_copper/nodes.lua @@ -61,7 +61,7 @@ local function set_tiles(tiles, index) end function mcl_copper.register_copper_variants(name, definitions) - local names, oxidized_variant, stripped_variant, waxed_variant + local names, oxidized_variant, stripped_variant, waxed_variant, tiles if name ~= "cut" then names = { @@ -79,12 +79,21 @@ function mcl_copper.register_copper_variants(name, definitions) } end - local tiles = { - "mcl_copper_"..name..".png", - "mcl_copper_"..name.."_exposed.png", - "mcl_copper_"..name.."_weathered.png", - "mcl_copper_"..name.."_oxidized.png" - } + if name == "block" then + tiles = { + "mcl_copper_block.png", + "mcl_copper_exposed.png", + "mcl_copper_weathered.png", + "mcl_copper_oxidized.png" + } + else + tiles = { + "mcl_copper_block_"..name..".png", + "mcl_copper_exposed_"..name..".png", + "mcl_copper_weathered_"..name..".png", + "mcl_copper_oxidized_"..name..".png" + } + end for i = 1, #names do if names[i]:find("waxed") then