summaryrefslogtreecommitdiff
path: root/lrfurn/armchairs.lua
diff options
context:
space:
mode:
Diffstat (limited to 'lrfurn/armchairs.lua')
-rw-r--r--lrfurn/armchairs.lua17
1 files changed, 6 insertions, 11 deletions
diff --git a/lrfurn/armchairs.lua b/lrfurn/armchairs.lua
index fc9d096..e471267 100644
--- a/lrfurn/armchairs.lua
+++ b/lrfurn/armchairs.lua
@@ -20,25 +20,20 @@ minetest.register_node("lrfurn:armchair", {
paramtype2 = "colorwallmounted",
palette = "unifieddyes_palette_colorwallmounted.png",
inventory_image = "lrfurn_armchair_inv.png",
- groups = {snappy=3},
+ groups = {snappy=3, ud_param2_colorable = 1},
sounds = default.node_sound_wood_defaults(),
node_box = armchair_cbox,
after_place_node = lrfurn.fix_rotation,
after_dig_node = unifieddyes.after_dig_node,
on_rightclick = function(pos, node, clicker, itemstack, pointed_thing)
local itemname = itemstack:get_name()
- if string.find(itemname, "dye:") or string.find(itemname, "unifieddyes:") then
- unifieddyes.on_rightclick(pos, node, clicker,
- itemstack, pointed_thing, "lrfurn:armchair", "wallmounted")
- else
- if not clicker:is_player() then
- return itemstack
- end
- pos.y = pos.y-0.5
- clicker:setpos(pos)
- clicker:set_hp(20)
+ if not clicker:is_player() then
return itemstack
end
+ pos.y = pos.y-0.5
+ clicker:setpos(pos)
+ clicker:set_hp(20)
+ return itemstack
end
})