From c1fee78e85f52e3b5c18bf2b2f56bc6926597868 Mon Sep 17 00:00:00 2001 From: Jeija Date: Sat, 26 Jan 2013 23:15:23 +0100 Subject: Place block when holding sneak while right-clicking nodes with formspec --- src/game.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/game.cpp b/src/game.cpp index 588a0fef3..e923cbbb0 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -2482,7 +2482,9 @@ void the_game( // Sign special case, at least until formspec is properly implemented. // Deprecated? - if(meta && meta->getString("formspec") == "hack:sign_text_input" && !random_input) + if(meta && meta->getString("formspec") == "hack:sign_text_input" + && !random_input + && !input->isKeyDown(getKeySetting("keymap_sneak"))) { infostream<<"Launching metadata text input"<drop(); } // If metadata provides an inventory view, activate it - else if(meta && meta->getString("formspec") != "" && !random_input) + else if(meta && meta->getString("formspec") != "" && !random_input + && !input->isKeyDown(getKeySetting("keymap_sneak"))) { infostream<<"Launching custom inventory view"<