]> git.lizzy.rs Git - xdecor.git/commitdiff
more tweaks
authorkilbith <jeanpatrick.guerrero@gmail.com>
Fri, 12 Jun 2015 14:08:43 +0000 (16:08 +0200)
committerkilbith <jeanpatrick.guerrero@gmail.com>
Fri, 12 Jun 2015 14:58:35 +0000 (16:58 +0200)
itemframes.lua
nodes.lua
textures/xdecor_wood_tile.png
workbench.lua

index 765c2d1552a3eb2d819a7683ae14b24aa981755b..5c9ef4076b0db92f46c4575cb5ca402b7e55041e 100644 (file)
@@ -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)
index 2490063317abf79ad58421148b94451f1df11d7b..7a7ed5dd073a6d2a2a2bb529eb7e53bd7c998368 100644 (file)
--- 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() })
index 87eac16a880ae7561124af4dfafdedd160e1e76e..b65f9d972e11062b1dd39d395af8e01dad27be31 100644 (file)
Binary files a/textures/xdecor_wood_tile.png and b/textures/xdecor_wood_tile.png differ
index a632dd9f02f2a43783725a59e02eefd926d91c0b..494994d44e9da72d93025c75f23d264cec8c55c3 100644 (file)
@@ -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