From 5f898982e282834cd2a8aec5f66466b7a995873f Mon Sep 17 00:00:00 2001 From: jp Date: Sun, 2 Aug 2015 23:47:02 +0200 Subject: [PATCH] Tweak node defs --- hive.lua | 2 +- mailbox.lua | 2 +- nodes.lua | 25 +++++++++++++------------ rope.lua | 2 +- worktable.lua | 2 +- xwall.lua | 24 +++++++++++------------- 6 files changed, 28 insertions(+), 29 deletions(-) diff --git a/hive.lua b/hive.lua index 03004ab..562d962 100644 --- a/hive.lua +++ b/hive.lua @@ -34,7 +34,7 @@ xdecor.register("hive", { "xdecor_hive_side.png", "xdecor_hive_front.png", }, - groups = {snappy=3, choppy=3, flammable=1}, + groups = {snappy=3, flammable=1}, on_construct = hive_construct, can_dig = hive_dig, on_punch = function(pos, node, puncher, pointed_thing) diff --git a/mailbox.lua b/mailbox.lua index 76273bf..3084b7d 100644 --- a/mailbox.lua +++ b/mailbox.lua @@ -5,7 +5,7 @@ xdecor.register("mailbox", { "xdecor_mailbox_side.png", "xdecor_mailbox_side.png", "xdecor_mailbox.png", "xdecor_mailbox.png", }, - groups = {snappy=2, cracky=2}, + groups = {cracky=2}, after_place_node = function(pos, placer, itemstack) local meta = minetest.get_meta(pos) local owner = placer:get_player_name() diff --git a/nodes.lua b/nodes.lua index bb6c8c7..e2ac268 100644 --- a/nodes.lua +++ b/nodes.lua @@ -31,7 +31,7 @@ xdecor.register("barrel", { inventory = {size=24}, infotext = "Barrel", tiles = {"xdecor_barrel_top.png", "xdecor_barrel_sides.png"}, - groups = {snappy=2, choppy=3, flammable=2}, + groups = {choppy=3, flammable=2}, sounds = xdecor.wood }) @@ -39,7 +39,7 @@ xdecor.register("cabinet", { description = "Cabinet", inventory = {size=24}, infotext = "Cabinet", - groups = {snappy=2, choppy=3}, + groups = {choppy=3, flammable=2}, sounds = xdecor.wood, tiles = { "default_wood.png", "default_wood.png", @@ -52,7 +52,7 @@ xdecor.register("cabinet_half", { description = "Half Cabinet", inventory = {size=8}, infotext = "Half Cabinet", - groups = {snappy=3, choppy=3, flammable=2}, + groups = {choppy=3, flammable=3}, sounds = xdecor.wood, node_box = xdecor.nodebox.slab_y(0.5, 0.5), tiles = { @@ -137,7 +137,7 @@ xdecor.register("chair", { description = "Chair", tiles = {"xdecor_wood.png"}, sounds = xdecor.wood, - groups = {snappy=2, choppy=3, flammable=2}, + groups = {choppy=3, flammable=2}, node_box = { type = "fixed", fixed = { @@ -255,7 +255,7 @@ xdecor.register("empty_shelf", { inventory = {size=24}, infotext = "Empty Shelf", tiles = {"default_wood.png", "xdecor_empty_shelf.png"}, - groups = {snappy=2, choppy=3, flammable=2}, + groups = {choppy=3, flammable=2}, sounds = xdecor.wood }) @@ -270,6 +270,7 @@ xdecor.register("enderchest", { "xdecor_enderchest_front.png" }, groups = {cracky=2}, + sounds = xdecor.stone, on_construct = function(pos) local meta = minetest.get_meta(pos) meta:set_string("formspec", @@ -415,7 +416,7 @@ xdecor.register("painting", { xdecor.register("plant_pot", { description = "Plant Pot", - groups = {snappy=3, cracky=3}, + groups = {snappy=3}, tiles = {"xdecor_plant_pot_top.png", "xdecor_plant_pot_bottom.png", "xdecor_plant_pot_sides.png"} }) @@ -423,7 +424,7 @@ xdecor.register("plant_pot", { xdecor.register("metal_cabinet", { description = "Metal Cabinet", inventory = {size=24}, - groups = {snappy=1, cracky=2}, + groups = {cracky=2}, infotext = "Metal Cabinet", tiles = { "xdecor_metal_cabinet_sides.png", "xdecor_metal_cabinet_sides.png", @@ -445,7 +446,7 @@ xdecor.register("multishelf", { inventory = {size=24}, infotext = "Multi Shelf", tiles = {"default_wood.png", "xdecor_multishelf.png"}, - groups = {snappy=2, choppy=3, flammable=2}, + groups = {choppy=3, flammable=2}, sounds = xdecor.wood }) @@ -518,7 +519,7 @@ xdecor.register("stone_tile", { xdecor.register("table", { description = "Table", tiles = {"xdecor_wood.png"}, - groups = {snappy=2, choppy=3, flammable=2}, + groups = {choppy=3, flammable=2}, sounds = xdecor.wood, node_box = { type = "fixed", @@ -544,7 +545,7 @@ xdecor.register("tatami", { xdecor.register("trash_can", { description = "Trash Can", tiles = {"xdecor_wood.png"}, - groups = {snappy=2, choppy=3, flammable=2}, + groups = {choppy=3, flammable=2}, sounds = xdecor.wood, node_box = { type = "fixed", @@ -600,7 +601,7 @@ xdecor.register("woodframed_glass", { description = "Wood Framed Glass", drawtype = "glasslike_framed", tiles = {"xdecor_framed_glass.png", "xdecor_framed_glass_detail.png"}, - groups = {snappy=2, cracky=3}, + groups = {cracky=3}, sounds = xdecor.glass }) @@ -608,6 +609,6 @@ xdecor.register("wood_tile", { description = "Wood Tile", tiles = {"xdecor_wood_tile.png"}, drawtype = "normal", - groups = {snappy=1, choppy=2, wood=1, flammable=2}, + groups = {choppy=2, wood=1, flammable=2}, sounds = xdecor.wood }) diff --git a/rope.lua b/rope.lua index dfc0ef3..43bd1e8 100644 --- a/rope.lua +++ b/rope.lua @@ -47,7 +47,7 @@ xdecor.register("rope", { drawtype = "plantlike", walkable = false, climbable = true, - groups = {dig_immediate=3, flammable=2}, + groups = {dig_immediate=3, flammable=3}, selection_box = rope_sbox, tiles = {"xdecor_rope.png"}, inventory_image = "xdecor_rope_inv.png", diff --git a/worktable.lua b/worktable.lua index 247bbcb..2583d96 100644 --- a/worktable.lua +++ b/worktable.lua @@ -110,7 +110,7 @@ end xdecor.register("worktable", { description = "Work Table", - groups = {snappy=3}, + groups = {cracky=3}, sounds = xdecor.wood, tiles = { "xdecor_worktable_top.png", "xdecor_worktable_top.png", diff --git a/xwall.lua b/xwall.lua index 97f4b7e..a0e74dc 100644 --- a/xwall.lua +++ b/xwall.lua @@ -183,20 +183,18 @@ local xwall_register_wall = function(name, tiles, def) {{ -0.2, -0.5, -0.5, 0.2, 5/16, 0.5 }} ) - if not def then - def = { - description = string.upper(string.sub(name, 8, 8))..string.sub(name, 9, -6).." ".. - string.upper(string.sub(name, -4, -4))..string.sub(name, -3), - textures = {tiles, tiles, tiles, tiles}, - sounds = xdecor.stone, - groups = {cracky=3, stone=1, pane=1}, - collision_box = { - type = "fixed", - fixed = {-0.5, -0.5, -0.25, 0.5, 1, 0.25} - } + if def then return end + def = { + description = string.upper(string.sub(name, 8, 8))..string.sub(name, 9, -6).." ".. + string.upper(string.sub(name, -4, -4))..string.sub(name, -3), + textures = {tiles, tiles, tiles, tiles}, + sounds = xdecor.stone, + groups = {cracky=3, stone=1, pane=1}, + collision_box = { + type = "fixed", + fixed = {-0.5, -0.5, -0.25, 0.5, 1, 0.25} } - end - + } xwall_register(name, def, node_box_data, selection_box_data) end