NoChargeException for teleport commands

This commit is contained in:
snowleo 2011-08-30 03:15:50 +02:00
parent 1cbdbc40a5
commit e9a14b204f
2 changed files with 15 additions and 0 deletions

View File

@ -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());

View File

@ -0,0 +1,10 @@
package com.earth2me.essentials.commands;
public class NoChargeException extends Exception
{
public NoChargeException()
{
super("Will charge later");
}
}