mirror of
				https://e.coding.net/circlecloud/YumCore.git
				synced 2025-11-03 23:06:02 +00:00 
			
		
		
		
	@@ -52,6 +52,12 @@ public class Log {
 | 
				
			|||||||
        logger.severe(msg);
 | 
					        logger.severe(msg);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    public static void toSender(final CommandSender sender, final String... msg) {
 | 
				
			||||||
 | 
					        for (final String str : msg) {
 | 
				
			||||||
 | 
					            sender.sendMessage(prefix + str);
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    public static void warning(final String msg) {
 | 
					    public static void warning(final String msg) {
 | 
				
			||||||
        logger.warning(msg);
 | 
					        logger.warning(msg);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,80 +1,53 @@
 | 
				
			|||||||
package pw.yumc.YumCore.commands;
 | 
					package pw.yumc.YumCore.commands;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import org.bukkit.command.Command;
 | 
					import org.bukkit.command.Command;
 | 
				
			||||||
import org.bukkit.command.CommandSender;
 | 
					import org.bukkit.command.CommandSender;
 | 
				
			||||||
import org.bukkit.entity.Player;
 | 
					
 | 
				
			||||||
 | 
					/**
 | 
				
			||||||
import pw.yumc.YumCore.commands.exception.IllegalPermissionException;
 | 
					 * 子命令参数类
 | 
				
			||||||
import pw.yumc.YumCore.commands.exception.IllegalSenderException;
 | 
					 *
 | 
				
			||||||
 | 
					 * @since 2015年8月22日上午8:29:44
 | 
				
			||||||
/**
 | 
					 * @author 喵♂呜
 | 
				
			||||||
 * 子命令调用事件类
 | 
					 */
 | 
				
			||||||
 *
 | 
					public class CommandArgument {
 | 
				
			||||||
 * @since 2015年8月22日上午8:29:44
 | 
					    private final CommandSender sender;
 | 
				
			||||||
 * @author 喵♂呜
 | 
					    private final Command command;
 | 
				
			||||||
 */
 | 
					    private final String alias;
 | 
				
			||||||
public class CommandArgument {
 | 
					    private final String[] args;
 | 
				
			||||||
    private final CommandSender sender;
 | 
					
 | 
				
			||||||
    private final Command command;
 | 
					    public CommandArgument(final CommandSender sender, final Command command, final String alias, final String[] args) {
 | 
				
			||||||
    private final String alias;
 | 
					        this.sender = sender;
 | 
				
			||||||
    private final String[] args;
 | 
					        this.command = command;
 | 
				
			||||||
 | 
					        this.alias = alias;
 | 
				
			||||||
    public CommandArgument(final CommandSender sender, final Command command, final String alias, final String[] args) {
 | 
					        this.args = args;
 | 
				
			||||||
        this.sender = sender;
 | 
					    }
 | 
				
			||||||
        this.command = command;
 | 
					
 | 
				
			||||||
        this.alias = alias;
 | 
					    /**
 | 
				
			||||||
        this.args = args;
 | 
					     * @return 命令别名
 | 
				
			||||||
    }
 | 
					     */
 | 
				
			||||||
 | 
					    public String getAlias() {
 | 
				
			||||||
    public boolean check(final CommandInfo info) {
 | 
					        return alias;
 | 
				
			||||||
        if (sender instanceof Player) {
 | 
					    }
 | 
				
			||||||
            if (info.getCommand().onlyConsoleExecutable()) {
 | 
					
 | 
				
			||||||
                throw new IllegalSenderException("§c玩家无法使用此命令(§4请使用控制台执行§c)!");
 | 
					    /**
 | 
				
			||||||
            }
 | 
					     * @return 命令参数
 | 
				
			||||||
        } else if (info.getCommand().onlyPlayerExecutable()) {
 | 
					     */
 | 
				
			||||||
            throw new IllegalSenderException("§c玩家无法使用此命令(§4请使用控制台执行§c)!");
 | 
					    public String[] getArgs() {
 | 
				
			||||||
        }
 | 
					        return args;
 | 
				
			||||||
        final String perm = info.getCommand().permission();
 | 
					    }
 | 
				
			||||||
        if (perm != null && !sender.hasPermission(perm)) {
 | 
					
 | 
				
			||||||
            throw new IllegalPermissionException("§c你需要有 " + perm + " 的权限才能执行此命令!");
 | 
					    /**
 | 
				
			||||||
        }
 | 
					     * @return 命令实体
 | 
				
			||||||
        return true;
 | 
					     */
 | 
				
			||||||
    }
 | 
					    public Command getCommand() {
 | 
				
			||||||
 | 
					        return command;
 | 
				
			||||||
    /**
 | 
					    }
 | 
				
			||||||
     * 命令别名
 | 
					
 | 
				
			||||||
     *
 | 
					    /**
 | 
				
			||||||
     * @return alias
 | 
					     * @return 命令发送者
 | 
				
			||||||
     */
 | 
					     */
 | 
				
			||||||
    public String getAlias() {
 | 
					    public CommandSender getSender() {
 | 
				
			||||||
        return alias;
 | 
					        return sender;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    /**
 | 
					}
 | 
				
			||||||
     * 命令参数
 | 
					 | 
				
			||||||
     *
 | 
					 | 
				
			||||||
     * @return args
 | 
					 | 
				
			||||||
     */
 | 
					 | 
				
			||||||
    public String[] getArgs() {
 | 
					 | 
				
			||||||
        return args;
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    /**
 | 
					 | 
				
			||||||
     * 命令实体
 | 
					 | 
				
			||||||
     *
 | 
					 | 
				
			||||||
     * @return command
 | 
					 | 
				
			||||||
     */
 | 
					 | 
				
			||||||
    public Command getCommand() {
 | 
					 | 
				
			||||||
        return command;
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    /**
 | 
					 | 
				
			||||||
     * 命令发送者
 | 
					 | 
				
			||||||
     *
 | 
					 | 
				
			||||||
     * @return sender
 | 
					 | 
				
			||||||
     */
 | 
					 | 
				
			||||||
    public CommandSender getSender() {
 | 
					 | 
				
			||||||
        return sender;
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,11 +1,11 @@
 | 
				
			|||||||
package pw.yumc.YumCore.commands.api;
 | 
					package pw.yumc.YumCore.commands;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/**
 | 
					/**
 | 
				
			||||||
 * 命令执行类
 | 
					 * 命令执行类
 | 
				
			||||||
 * 
 | 
					 * 
 | 
				
			||||||
 * @since 2016年7月23日 上午9:55:51
 | 
					 * @since 2016年7月23日 上午9:55:51
 | 
				
			||||||
 * @author 喵♂呜
 | 
					 * @author 喵♂呜
 | 
				
			||||||
 */
 | 
					 */
 | 
				
			||||||
public interface CommandExecutor {
 | 
					public interface CommandExecutor {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
@@ -6,9 +6,10 @@ import java.util.Arrays;
 | 
				
			|||||||
import java.util.List;
 | 
					import java.util.List;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
import org.bukkit.Bukkit;
 | 
					import org.bukkit.Bukkit;
 | 
				
			||||||
import org.bukkit.command.Command;
 | 
					 | 
				
			||||||
import org.bukkit.command.CommandSender;
 | 
					import org.bukkit.command.CommandSender;
 | 
				
			||||||
 | 
					import org.bukkit.entity.Player;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					import pw.yumc.YumCore.bukkit.Log;
 | 
				
			||||||
import pw.yumc.YumCore.bukkit.P;
 | 
					import pw.yumc.YumCore.bukkit.P;
 | 
				
			||||||
import pw.yumc.YumCore.commands.annotation.Async;
 | 
					import pw.yumc.YumCore.commands.annotation.Async;
 | 
				
			||||||
import pw.yumc.YumCore.commands.annotation.Cmd;
 | 
					import pw.yumc.YumCore.commands.annotation.Cmd;
 | 
				
			||||||
@@ -23,7 +24,13 @@ import pw.yumc.YumCore.commands.exception.CommandException;
 | 
				
			|||||||
 * @author 喵♂呜
 | 
					 * @author 喵♂呜
 | 
				
			||||||
 */
 | 
					 */
 | 
				
			||||||
public class CommandInfo {
 | 
					public class CommandInfo {
 | 
				
			||||||
    public static CommandInfo Unknow = new CommandInfo();
 | 
					    public static final CommandInfo Unknow = new CommandInfo();
 | 
				
			||||||
 | 
					    private static final String onlyPlayer = "§c控制台无法使用此命令(§4请在游戏内执行§c)!";
 | 
				
			||||||
 | 
					    private static final String onlyConsole = "§c玩家无法使用此命令(§4请使用控制台执行§c)!";
 | 
				
			||||||
 | 
					    private static final String losePerm = "§c你需要有 %s 的权限才能执行此命令!";
 | 
				
			||||||
 | 
					    private static final String cmdErr = "§6错误原因: §4命令参数不正确!";
 | 
				
			||||||
 | 
					    private static final String cmdUse = "§6使用方法: §e/%s %s %s";
 | 
				
			||||||
 | 
					    private static final String cmdDes = "§6命令描述: §3%s";
 | 
				
			||||||
    private final Object origin;
 | 
					    private final Object origin;
 | 
				
			||||||
    private final Method method;
 | 
					    private final Method method;
 | 
				
			||||||
    private final String name;
 | 
					    private final String name;
 | 
				
			||||||
@@ -55,6 +62,15 @@ public class CommandInfo {
 | 
				
			|||||||
        this.sort = 0;
 | 
					        this.sort = 0;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * 解析CommandInfo
 | 
				
			||||||
 | 
					     *
 | 
				
			||||||
 | 
					     * @param method
 | 
				
			||||||
 | 
					     *            方法
 | 
				
			||||||
 | 
					     * @param origin
 | 
				
			||||||
 | 
					     *            源对象
 | 
				
			||||||
 | 
					     * @return {@link CommandInfo}
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
    public static CommandInfo parse(final Method method, final Object origin) {
 | 
					    public static CommandInfo parse(final Method method, final Object origin) {
 | 
				
			||||||
        final Cmd command = method.getAnnotation(Cmd.class);
 | 
					        final Cmd command = method.getAnnotation(Cmd.class);
 | 
				
			||||||
        if (command != null) {
 | 
					        if (command != null) {
 | 
				
			||||||
@@ -74,21 +90,28 @@ public class CommandInfo {
 | 
				
			|||||||
        return super.equals(obj);
 | 
					        return super.equals(obj);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    public boolean execute(final CommandSender sender, final Command command, final String label, final String[] args) {
 | 
					    /**
 | 
				
			||||||
 | 
					     * 执行命令
 | 
				
			||||||
 | 
					     *
 | 
				
			||||||
 | 
					     * @param sender
 | 
				
			||||||
 | 
					     *            命令发送者
 | 
				
			||||||
 | 
					     * @param command
 | 
				
			||||||
 | 
					     *            主命令
 | 
				
			||||||
 | 
					     * @param label
 | 
				
			||||||
 | 
					     *            主命令别名
 | 
				
			||||||
 | 
					     * @param args
 | 
				
			||||||
 | 
					     *            子命令参数
 | 
				
			||||||
 | 
					     * @return
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
 | 
					    public boolean execute(final CommandArgument cmdArgs) {
 | 
				
			||||||
        if (method == null) {
 | 
					        if (method == null) {
 | 
				
			||||||
            return false;
 | 
					            return false;
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        final CommandArgument cmdArgs = new CommandArgument(sender, command, label, args);
 | 
					        check(cmdArgs);
 | 
				
			||||||
        final Runnable runnable = new Runnable() {
 | 
					        final Runnable runnable = new Runnable() {
 | 
				
			||||||
            @Override
 | 
					            @Override
 | 
				
			||||||
            public void run() {
 | 
					            public void run() {
 | 
				
			||||||
                try {
 | 
					                try {
 | 
				
			||||||
                    try {
 | 
					 | 
				
			||||||
                        cmdArgs.check(CommandInfo.this);
 | 
					 | 
				
			||||||
                    } catch (final CommandException e) {
 | 
					 | 
				
			||||||
                        sender.sendMessage(e.getMessage());
 | 
					 | 
				
			||||||
                        return;
 | 
					 | 
				
			||||||
                    }
 | 
					 | 
				
			||||||
                    method.invoke(origin, cmdArgs);
 | 
					                    method.invoke(origin, cmdArgs);
 | 
				
			||||||
                } catch (IllegalAccessException | IllegalArgumentException | InvocationTargetException e) {
 | 
					                } catch (IllegalAccessException | IllegalArgumentException | InvocationTargetException e) {
 | 
				
			||||||
                    throw new CommandException(e);
 | 
					                    throw new CommandException(e);
 | 
				
			||||||
@@ -103,27 +126,75 @@ public class CommandInfo {
 | 
				
			|||||||
        return true;
 | 
					        return true;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * @return 命令注解
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
    public Cmd getCommand() {
 | 
					    public Cmd getCommand() {
 | 
				
			||||||
        return command;
 | 
					        return command;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * @return 帮助注解
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
    public Help getHelp() {
 | 
					    public Help getHelp() {
 | 
				
			||||||
        return help;
 | 
					        return help;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * @return 命令名称
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
    public String getName() {
 | 
					    public String getName() {
 | 
				
			||||||
        return name;
 | 
					        return name;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * @return 命令排序
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
    public int getSort() {
 | 
					    public int getSort() {
 | 
				
			||||||
        return sort;
 | 
					        return sort;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * @return 是否为异步命令
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
    public boolean isAsync() {
 | 
					    public boolean isAsync() {
 | 
				
			||||||
        return async;
 | 
					        return async;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * 验证命令是否匹配
 | 
				
			||||||
 | 
					     *
 | 
				
			||||||
 | 
					     * @param cmd
 | 
				
			||||||
 | 
					     *            需验证命令
 | 
				
			||||||
 | 
					     * @return 是否匹配
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
    public boolean isValid(final String cmd) {
 | 
					    public boolean isValid(final String cmd) {
 | 
				
			||||||
        return name.equalsIgnoreCase(cmd) || aliases.contains(cmd);
 | 
					        return name.equalsIgnoreCase(cmd) || aliases.contains(cmd);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * 检查命令
 | 
				
			||||||
 | 
					     *
 | 
				
			||||||
 | 
					     * @param info
 | 
				
			||||||
 | 
					     *            命令信息
 | 
				
			||||||
 | 
					     * @return 是否验证通过
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
 | 
					    private boolean check(final CommandArgument cmdArgs) {
 | 
				
			||||||
 | 
					        final CommandSender sender = cmdArgs.getSender();
 | 
				
			||||||
 | 
					        if (cmdArgs.getArgs().length < command.minimumArguments()) {
 | 
				
			||||||
 | 
					            Log.toSender(sender, cmdErr);
 | 
				
			||||||
 | 
					            Log.toSender(sender, String.format(cmdUse, cmdArgs.getAlias(), getName(), help.possibleArguments()));
 | 
				
			||||||
 | 
					            Log.toSender(sender, String.format(cmdDes, help.description()));
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					        if (sender instanceof Player && command.onlyConsoleExecutable()) {
 | 
				
			||||||
 | 
					            Log.toSender(sender, onlyConsole);
 | 
				
			||||||
 | 
					        } else if (command.onlyPlayerExecutable()) {
 | 
				
			||||||
 | 
					            Log.toSender(sender, onlyPlayer);
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					        final String perm = command.permission();
 | 
				
			||||||
 | 
					        if (perm != null && !sender.hasPermission(perm)) {
 | 
				
			||||||
 | 
					            Log.toSender(sender, String.format(losePerm, perm));
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					        return true;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -20,7 +20,6 @@ import org.bukkit.util.StringUtil;
 | 
				
			|||||||
import pw.yumc.YumCore.bukkit.Log;
 | 
					import pw.yumc.YumCore.bukkit.Log;
 | 
				
			||||||
import pw.yumc.YumCore.bukkit.P;
 | 
					import pw.yumc.YumCore.bukkit.P;
 | 
				
			||||||
import pw.yumc.YumCore.bukkit.compatible.C;
 | 
					import pw.yumc.YumCore.bukkit.compatible.C;
 | 
				
			||||||
import pw.yumc.YumCore.commands.api.CommandExecutor;
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
/**
 | 
					/**
 | 
				
			||||||
 * 命令管理类
 | 
					 * 命令管理类
 | 
				
			||||||
@@ -96,19 +95,13 @@ public class CommandManager implements TabExecutor {
 | 
				
			|||||||
            help.send(sender, command, label, args);
 | 
					            help.send(sender, command, label, args);
 | 
				
			||||||
            return true;
 | 
					            return true;
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        final String[] subargs = moveStrings(args, 1);
 | 
					        final CommandArgument cmdArgs = new CommandArgument(sender, command, label, moveStrings(args, 1));
 | 
				
			||||||
        if (!cmdcache.containsKey(label)) {
 | 
					        final CommandInfo ci = checkCache(subcmd);
 | 
				
			||||||
            for (final CommandInfo cmdinfo : cmdlist) {
 | 
					        try {
 | 
				
			||||||
                if (cmdinfo.isValid(subcmd)) {
 | 
					
 | 
				
			||||||
                    cmdcache.put(subcmd, cmdinfo);
 | 
					        } catch (final Exception e) {
 | 
				
			||||||
                    break;
 | 
					 | 
				
			||||||
                }
 | 
					 | 
				
			||||||
            }
 | 
					 | 
				
			||||||
            if (!cmdcache.containsKey(subcmd)) {
 | 
					 | 
				
			||||||
                cmdcache.put(subcmd, CommandInfo.Unknow);
 | 
					 | 
				
			||||||
            }
 | 
					 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        return cmdcache.get(subcmd).execute(sender, command, label, subargs);
 | 
					        return ci.execute(cmdArgs);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    @Override
 | 
					    @Override
 | 
				
			||||||
@@ -145,6 +138,28 @@ public class CommandManager implements TabExecutor {
 | 
				
			|||||||
        help = new CommandHelp(cmdlist);
 | 
					        help = new CommandHelp(cmdlist);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    /**
 | 
				
			||||||
 | 
					     * 检查缓存并获得命令
 | 
				
			||||||
 | 
					     *
 | 
				
			||||||
 | 
					     * @param subcmd
 | 
				
			||||||
 | 
					     *            子命令
 | 
				
			||||||
 | 
					     * @return 命令信息
 | 
				
			||||||
 | 
					     */
 | 
				
			||||||
 | 
					    private CommandInfo checkCache(final String subcmd) {
 | 
				
			||||||
 | 
					        if (!cmdcache.containsKey(subcmd)) {
 | 
				
			||||||
 | 
					            for (final CommandInfo cmdinfo : cmdlist) {
 | 
				
			||||||
 | 
					                if (cmdinfo.isValid(subcmd)) {
 | 
				
			||||||
 | 
					                    cmdcache.put(subcmd, cmdinfo);
 | 
				
			||||||
 | 
					                    break;
 | 
				
			||||||
 | 
					                }
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					            if (!cmdcache.containsKey(subcmd)) {
 | 
				
			||||||
 | 
					                cmdcache.put(subcmd, CommandInfo.Unknow);
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					        return cmdcache.get(subcmd);
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    /**
 | 
					    /**
 | 
				
			||||||
     * 获取玩家命令补全
 | 
					     * 获取玩家命令补全
 | 
				
			||||||
     *
 | 
					     *
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1,14 +0,0 @@
 | 
				
			|||||||
package pw.yumc.YumCore.commands.exception;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
/**
 | 
					 | 
				
			||||||
 *
 | 
					 | 
				
			||||||
 * @since 2016年7月23日 上午11:00:34
 | 
					 | 
				
			||||||
 * @author 喵♂呜
 | 
					 | 
				
			||||||
 */
 | 
					 | 
				
			||||||
public class IllegalArgumentException extends CommandException {
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    public IllegalArgumentException(final String string) {
 | 
					 | 
				
			||||||
        super(string);
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@@ -1,12 +0,0 @@
 | 
				
			|||||||
package pw.yumc.YumCore.commands.exception;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
/**
 | 
					 | 
				
			||||||
 *
 | 
					 | 
				
			||||||
 * @since 2016年7月23日 上午10:50:23
 | 
					 | 
				
			||||||
 * @author 喵♂呜
 | 
					 | 
				
			||||||
 */
 | 
					 | 
				
			||||||
public class IllegalPermissionException extends CommandException {
 | 
					 | 
				
			||||||
    public IllegalPermissionException(final String string) {
 | 
					 | 
				
			||||||
        super(string);
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
@@ -1,14 +0,0 @@
 | 
				
			|||||||
package pw.yumc.YumCore.commands.exception;
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
/**
 | 
					 | 
				
			||||||
 *
 | 
					 | 
				
			||||||
 * @since 2016年7月23日 上午11:00:34
 | 
					 | 
				
			||||||
 * @author 喵♂呜
 | 
					 | 
				
			||||||
 */
 | 
					 | 
				
			||||||
public class IllegalSenderException extends CommandException {
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    public IllegalSenderException(final String string) {
 | 
					 | 
				
			||||||
        super(string);
 | 
					 | 
				
			||||||
    }
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					 | 
				
			||||||
		Reference in New Issue
	
	Block a user