From 19548afbbcc0abd86666df32c7c01655aa011b5a Mon Sep 17 00:00:00 2001 From: Sn0wStorm Date: Thu, 24 Oct 2013 14:16:41 +0200 Subject: [PATCH] Prevent Rightclick on Interact Signs --- src/com/dre/dungeonsxl/listener/PlayerListener.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/com/dre/dungeonsxl/listener/PlayerListener.java b/src/com/dre/dungeonsxl/listener/PlayerListener.java index d51e2335..90f14c85 100644 --- a/src/com/dre/dungeonsxl/listener/PlayerListener.java +++ b/src/com/dre/dungeonsxl/listener/PlayerListener.java @@ -163,7 +163,11 @@ public class PlayerListener implements Listener { // Trigger InteractTrigger InteractTrigger trigger = InteractTrigger.get(clickedBlock, gworld); if (trigger != null) { - trigger.onTrigger(player); + if (event.getAction() == Action.LEFT_CLICK_BLOCK) { + trigger.onTrigger(player); + } else { + p.msg(player, p.language.get("Error_Leftklick")); + } } // Class Signs