Tweaks to command system to allow setting executors via plugins (no more ambiguous onCommand in plugins)
By: Dinnerbone <dinnerbone@dinnerbone.com>
This commit is contained in:
@@ -23,7 +23,7 @@ public final class SimpleCommandMap implements CommandMap {
|
||||
private void setDefaultCommands(final Server server) {
|
||||
register("bukkit", new VersionCommand("version", server));
|
||||
register("bukkit", new ReloadCommand("reload", server));
|
||||
register("bukkit", new PluginsCommand("plugins",server));
|
||||
register("bukkit", new PluginsCommand("plugins", server));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -91,6 +91,10 @@ public final class SimpleCommandMap implements CommandMap {
|
||||
}
|
||||
}
|
||||
|
||||
public Command getCommand(String name) {
|
||||
return knownCommands.get(name);
|
||||
}
|
||||
|
||||
private static class VersionCommand extends Command {
|
||||
private final Server server;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user