diff options
author | Dinnerbone <dinnerbone@dinnerbone.com> | 2011-06-26 02:46:04 +0100 |
---|---|---|
committer | Dinnerbone <dinnerbone@dinnerbone.com> | 2011-06-26 02:46:04 +0100 |
commit | 528e8c7221b1aaa8308d76c3b18dc2a7de9f3610 (patch) | |
tree | 5ce90f822ee04b1dbb39964aff9cbb800e0f8b06 /src/main | |
parent | 0b92a51ba70ea8112aee6a8fd735456994c03fd2 (diff) | |
download | craftbukkit-528e8c7221b1aaa8308d76c3b18dc2a7de9f3610.tar craftbukkit-528e8c7221b1aaa8308d76c3b18dc2a7de9f3610.tar.gz craftbukkit-528e8c7221b1aaa8308d76c3b18dc2a7de9f3610.tar.lz craftbukkit-528e8c7221b1aaa8308d76c3b18dc2a7de9f3610.tar.xz craftbukkit-528e8c7221b1aaa8308d76c3b18dc2a7de9f3610.zip |
Don't register commands only on init
Diffstat (limited to 'src/main')
-rw-r--r-- | src/main/java/org/bukkit/craftbukkit/CraftServer.java | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java index 019a0b14..46c58109 100644 --- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java +++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java @@ -66,10 +66,10 @@ public final class CraftServer implements Server { private final String serverName = "Craftbukkit"; private final String serverVersion; private final String protocolVersion = "1.6.6"; - private final PluginManager pluginManager = new SimplePluginManager(this); private final ServicesManager servicesManager = new SimpleServicesManager(); private final BukkitScheduler scheduler = new CraftScheduler(this); private final SimpleCommandMap commandMap = new SimpleCommandMap(this); + private final PluginManager pluginManager = new SimplePluginManager(this, commandMap); protected final MinecraftServer console; protected final ServerConfigurationManager server; private final Map<String, World> worlds = new LinkedHashMap<String, World>(); @@ -147,12 +147,6 @@ public final class CraftServer implements Server { } private void loadPlugin(Plugin plugin) { - List<Command> pluginCommands = PluginCommandYamlParser.parse(plugin); - - if (!pluginCommands.isEmpty()) { - commandMap.registerAll(plugin.getDescription().getName(), pluginCommands); - } - try { pluginManager.enablePlugin(plugin); } catch (Throwable ex) { |