summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVanessa Dannenberg <vanessa.e.dannenberg@gmail.com>2018-08-26 08:28:56 -0400
committerVanessa Dannenberg <vanessa.e.dannenberg@gmail.com>2018-08-26 08:28:56 -0400
commite13d514ff752a39cdd15376db89a3ca9ab68770b (patch)
tree4302b166318cbabcf42dad9e03bd8938aaa09fd8
parentfa71e3166c7029fb102ab039e798a01cbff857e2 (diff)
downloadunifieddyes-e13d514ff752a39cdd15376db89a3ca9ab68770b.tar
unifieddyes-e13d514ff752a39cdd15376db89a3ca9ab68770b.tar.gz
unifieddyes-e13d514ff752a39cdd15376db89a3ca9ab68770b.tar.bz2
unifieddyes-e13d514ff752a39cdd15376db89a3ca9ab68770b.tar.xz
unifieddyes-e13d514ff752a39cdd15376db89a3ca9ab68770b.zip
allow shift-punch for airbrush form
-rw-r--r--init.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/init.lua b/init.lua
index 4ebcded..90d9fa6 100644
--- a/init.lua
+++ b/init.lua
@@ -644,7 +644,11 @@ function unifieddyes.on_airbrush(itemstack, player, pointed_thing)
end
local pos = minetest.get_pointed_thing_position(pointed_thing)
- if not pos then unifieddyes.show_airbrush_form(player) return end
+ if not pos or player:get_player_control().sneak then
+ unifieddyes.show_airbrush_form(player)
+ return
+ end
+
if not painting_with then return end
local node = minetest.get_node(pos)