projects
/
oweals
/
minetest_game.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9ab5070
)
Make doors place when shift is held instead of calling on_rightclick
author
rubenwardy
<rubenwardy@gmail.com>
Tue, 3 Jan 2017 16:54:01 +0000
(16:54 +0000)
committer
GitHub
<noreply@github.com>
Tue, 3 Jan 2017 16:54:01 +0000
(16:54 +0000)
Fixes #1364
mods/doors/init.lua
patch
|
blob
|
history
diff --git
a/mods/doors/init.lua
b/mods/doors/init.lua
index c5d4a140a8217586df6e1acfaa381209e42c15ed..ae257fb65e13a7100b4050c70f21d092a5de68e8 100644
(file)
--- a/
mods/doors/init.lua
+++ b/
mods/doors/init.lua
@@
-265,7
+265,8
@@
function doors.register(name, def)
local node = minetest.get_node(pointed_thing.under)
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,
node, placer, itemstack, pointed_thing)
end