shift+rightclick places door when clicking on another door :)

This commit is contained in:
TenPlus1 2017-01-03 11:29:32 +00:00
parent cc2ff88cd0
commit cc04306bd2

View File

@ -270,7 +270,8 @@ function doors.register(name, def)
local node = minetest.get_node(pointed_thing.under) local node = minetest.get_node(pointed_thing.under)
local pdef = minetest.registered_nodes[node.name] local pdef = minetest.registered_nodes[node.name]
if pdef and pdef.on_rightclick then if pdef and pdef.on_rightclick and
not placer:get_player_control().sneak then
return pdef.on_rightclick(pointed_thing.under, return pdef.on_rightclick(pointed_thing.under,
node, placer, itemstack, pointed_thing) node, placer, itemstack, pointed_thing)
end end