diff --git a/itemframes.lua b/itemframes.lua index 765c2d1..5c9ef40 100644 --- a/itemframes.lua +++ b/itemframes.lua @@ -78,8 +78,8 @@ end xdecor.register("frame", { description = "Item frame", groups = {snappy=3}, on_rotate = screwdriver.disallow, node_box = { type = "fixed", fixed = {-0.5, -0.5, 7/16, 0.5, 0.5, 0.5} }, - tiles = {"xdecor_wood_tile.png", "xdecor_wood_tile.png", "xdecor_wood_tile.png", - "xdecor_wood_tile.png", "xdecor_wood_tile.png", "xdecor_frame.png"}, + tiles = {"xdecor_wood.png", "xdecor_wood.png", "xdecor_wood.png", + "xdecor_wood.png", "xdecor_wood.png", "xdecor_frame.png"}, inventory_image = "xdecor_frame.png", after_place_node = function(pos, placer, itemstack) local meta = minetest.get_meta(pos) diff --git a/nodes.lua b/nodes.lua index 2490063..7a7ed5d 100644 --- a/nodes.lua +++ b/nodes.lua @@ -47,7 +47,7 @@ xdecor.register("cauldron", { "xdecor_cauldron_sides.png"} }) xdecor.register("chair", { - description = "Chair", tiles = {"xdecor_wood_tile.png"}, + description = "Chair", tiles = {"xdecor_wood.png"}, sounds = default.node_sound_wood_defaults(), groups = {snappy=3}, node_box = {type="fixed", fixed={ {-0.3125, -0.5, 0.1875, -0.1875, 0.5, 0.3125}, @@ -60,11 +60,11 @@ xdecor.register("chair", { xdecor.register("chandelier", { description = "Chandelier", drawtype = "plantlike", walkable = false, inventory_image = "xdecor_chandelier.png", tiles = {"xdecor_chandelier.png"}, - groups = {dig_immediate=3}, light_source = 15 }) + groups = {dig_immediate=3}, light_source = 14 }) xdecor.register("coalstone_tile", { description = "Coalstone Tile", tiles = {"xdecor_coalstone_tile.png"}, - groups = {snappy=3}, sounds = default.node_sound_stone_defaults() }) + groups = {snappy=2}, sounds = default.node_sound_stone_defaults() }) local curtaincolors = {"red"} -- add more curtains simply here for _, c in ipairs(curtaincolors) do @@ -108,9 +108,10 @@ xdecor.register("empty_shelf", { tiles = {"default_wood.png", "xdecor_empty_shelf.png"}, groups = {snappy=3}, sounds = default.node_sound_wood_defaults() }) +local fence_sbox = {type="fixed", fixed={-1/7, -1/2, -1/7, 1/7, 1/2, 1/7}} xdecor.register("fence_wrought_iron", { - description = "Wrought Iron Fence", drawtype = "fencelike", - tiles = {"default_stone.png^[colorize:#2a2420:180"}, groups = {snappy=3}, + description = "Wrought Iron Fence", drawtype = "fencelike", groups = {snappy=2}, + tiles = {"default_stone.png^[colorize:#2a2420:180"}, selection_box = fence_sbox, inventory_image = "default_fence_overlay.png^default_stone.png^[colorize:#2a2420:160^default_fence_overlay.png^[makealpha:255,126,126" }) xdecor.register("fire", { @@ -177,11 +178,11 @@ xdecor.register("metal_cabinet", { tiles = {"xdecor_metal_cabinet_sides.png", "xdecor_metal_cabinet_sides.png", "xdecor_metal_cabinet_sides.png", "xdecor_metal_cabinet_sides.png", "xdecor_metal_cabinet_sides.png", "xdecor_metal_cabinet_front.png"}, - groups = {snappy=2}, infotext = "Metal Cabinet" }) + groups = {snappy=1}, infotext = "Metal Cabinet" }) xdecor.register("moonbrick", { description = "Moonbrick", tiles = {"xdecor_moonbrick.png"}, - groups = {snappy=3}, sounds = default.node_sound_stone_defaults() }) + groups = {snappy=2}, sounds = default.node_sound_stone_defaults() }) xdecor.register("multishelf", { description = "Multi Shelf", inventory = {size=24}, infotext = "Multi Shelf", @@ -210,7 +211,7 @@ xdecor.register("stone_tile", { groups = {snappy=3}, sounds = default.node_sound_stone_defaults() }) xdecor.register("table", { - description = "Table", tiles = {"xdecor_wood_tile.png"}, + description = "Table", tiles = {"xdecor_wood.png"}, groups = {snappy=3}, sounds = default.node_sound_wood_defaults(), node_box = {type="fixed", fixed={ {-0.5, 0.4, -0.5, 0.5, 0.5, 0.5}, @@ -234,4 +235,4 @@ xdecor.register("woodframed_glass", { xdecor.register("wood_tile", { description = "Wood Tile", tiles = {"xdecor_wood_tile.png"}, - groups = {snappy=3, wood=1}, sounds = default.node_sound_wood_defaults() }) + groups = {snappy=2, wood=1}, sounds = default.node_sound_wood_defaults() }) diff --git a/textures/xdecor_wood_tile.png b/textures/xdecor_wood_tile.png index 87eac16..b65f9d9 100644 Binary files a/textures/xdecor_wood_tile.png and b/textures/xdecor_wood_tile.png differ diff --git a/workbench.lua b/workbench.lua index a632dd9..494994d 100644 --- a/workbench.lua +++ b/workbench.lua @@ -9,7 +9,7 @@ xdecor.register("workbench", { on_construct = function(pos) local meta = minetest.get_meta(pos) meta:set_string("formspec", "size[8,7;]"..fancy_gui.. - "label[0,0;Cut your wood tile into...]".. + "label[0,0;Cut your wood into...]".. "label[0,1.5;Input]".. "list[current_name;input;0,2;1,1;]".. "image[1,2;1,1;xdecor_saw.png]".. @@ -53,7 +53,7 @@ xdecor.register("workbench", { else return end local inputstack = inv:get_stack("input", 1) - if (inputstack:get_name() == "xdecor:wood_tile") then + if (inputstack:get_name() == "default:wood") then local give = {} for i = 0, anz-1 do give[i+1] = inv:add_item("output", shape) @@ -65,8 +65,12 @@ xdecor.register("workbench", { can_dig = function(pos, player) local meta = minetest.get_meta(pos) local inv = meta:get_inventory() - return inv:is_empty("src") and inv:is_empty("fuel") - and inv:is_empty("input") and inv:is_empty("output") + if not inv:is_empty("input") + or not inv:is_empty("output") + or not inv:is_empty("fuel") + or not inv:is_empty("src") then + return false end + return true end }) @@ -76,16 +80,16 @@ local function register_wood_cut(name, desc, box, f_groups) f_groups.not_in_creative_inventory = 1 xdecor.register(name.."_wood", { description = "Wood "..desc, - tiles = {"xdecor_wood_tile.png"}, groups = f_groups, + tiles = {"default_wood.png"}, groups = f_groups, sounds = default.node_sound_wood_defaults(), node_box = { type = "fixed", fixed = box } }) end wood = {} wood.datas = { - {"microslab", "Microslab", { -0.5, -0.5, -0.5, 0.5, -0.4375, 0.5 }}, - {"microslab_half", "Half Microslab", { -0.5, -0.5, -0.5, 0.5, -0.4375, 0 }}, - {"microcube", "Microcube", { -0.5, -0.5, -0.5, 0, 0, 0 }}, - {"panel", "Panel", { -0.5, -0.5, -0.5, 0.5, 0, 0 }}, + {"microslab", "Microslab", {-0.5, -0.5, -0.5, 0.5, -0.4375, 0.5}}, + {"microslab_half", "Half Microslab", {-0.5, -0.5, -0.5, 0.5, -0.4375, 0}}, + {"microcube", "Microcube", {-0.5, -0.5, -0.5, 0, 0, 0}}, + {"panel", "Panel", {-0.5, -0.5, -0.5, 0.5, 0, 0}}, } for _, item in pairs(wood.datas) do