summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsnowleo <schneeleo@gmail.com>2011-08-30 03:15:50 +0200
committersnowleo <schneeleo@gmail.com>2011-08-30 03:15:50 +0200
commit731d177b6af3623c4b84a086b954923039f62e17 (patch)
tree872bfe91b0d6cef01f37ca3e18d073f0c471cab6
parentfd563364e5d6526ed31ce88b70701e64c2f5bc38 (diff)
downloadEssentials-731d177b6af3623c4b84a086b954923039f62e17.tar
Essentials-731d177b6af3623c4b84a086b954923039f62e17.tar.gz
Essentials-731d177b6af3623c4b84a086b954923039f62e17.tar.lz
Essentials-731d177b6af3623c4b84a086b954923039f62e17.tar.xz
Essentials-731d177b6af3623c4b84a086b954923039f62e17.zip
NoChargeException for teleport commands
-rw-r--r--Essentials/src/com/earth2me/essentials/Essentials.java5
-rw-r--r--Essentials/src/com/earth2me/essentials/commands/NoChargeException.java10
2 files changed, 15 insertions, 0 deletions
diff --git a/Essentials/src/com/earth2me/essentials/Essentials.java b/Essentials/src/com/earth2me/essentials/Essentials.java
index 883389625..3ea10f64a 100644
--- a/Essentials/src/com/earth2me/essentials/Essentials.java
+++ b/Essentials/src/com/earth2me/essentials/Essentials.java
@@ -28,6 +28,7 @@ import org.bukkit.*;
import org.bukkit.command.Command;
import org.bukkit.command.CommandSender;
import com.earth2me.essentials.commands.IEssentialsCommand;
+import com.earth2me.essentials.commands.NoChargeException;
import com.earth2me.essentials.commands.NotEnoughArgumentsException;
import com.earth2me.essentials.register.payment.Methods;
import com.earth2me.essentials.signs.SignBlockListener;
@@ -451,6 +452,10 @@ public class Essentials extends JavaPlugin implements IEssentials
}
return true;
}
+ catch (NoChargeException ex)
+ {
+ return true;
+ }
catch (NotEnoughArgumentsException ex)
{
sender.sendMessage(command.getDescription());
diff --git a/Essentials/src/com/earth2me/essentials/commands/NoChargeException.java b/Essentials/src/com/earth2me/essentials/commands/NoChargeException.java
new file mode 100644
index 000000000..bb0088792
--- /dev/null
+++ b/Essentials/src/com/earth2me/essentials/commands/NoChargeException.java
@@ -0,0 +1,10 @@
+package com.earth2me.essentials.commands;
+
+
+public class NoChargeException extends Exception
+{
+ public NoChargeException()
+ {
+ super("Will charge later");
+ }
+}