summaryrefslogtreecommitdiff
path: root/builtin
diff options
context:
space:
mode:
authorPilzAdam <adam-k@outlook.com>2012-12-01 15:20:53 +0100
committerPilzAdam <adam-k@outlook.com>2012-12-01 15:20:53 +0100
commitfa50341a71bbda80240d9a7e326dfe3bcd5b63e5 (patch)
treeb8b7013ab9acad85d8e4b6d7b26e6bcb5ac4e02c /builtin
parentfa76057e7f6811a8e7388a70d6fde7af61aa0bee (diff)
downloadminetest-fa50341a71bbda80240d9a7e326dfe3bcd5b63e5.tar.gz
minetest-fa50341a71bbda80240d9a7e326dfe3bcd5b63e5.tar.bz2
minetest-fa50341a71bbda80240d9a7e326dfe3bcd5b63e5.zip
Only check attachment for nodes with group attached_node
Diffstat (limited to 'builtin')
-rw-r--r--builtin/item.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/builtin/item.lua b/builtin/item.lua
index 9352a43fc..4be77e1d7 100644
--- a/builtin/item.lua
+++ b/builtin/item.lua
@@ -182,7 +182,8 @@ function minetest.item_place_node(itemstack, placer, pointed_thing)
end
-- Check if the node is attached and if it can be placed there
- if not check_attached_node(place_to, newnode) then
+ if minetest.get_item_group(def.name, "attached_node") ~= 0 and
+ not check_attached_node(place_to, newnode) then
minetest.log("action", "attached node " .. def.name ..
" can not be placed at " .. minetest.pos_to_string(place_to))
return