cn.nukkit.plugin.PluginLoadOrder Java Examples
The following examples show how to use
cn.nukkit.plugin.PluginLoadOrder.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: Server.java From Jupiter with GNU General Public License v3.0 | 5 votes |
public void enablePlugins(PluginLoadOrder type) { for (Plugin plugin : new ArrayList<>(this.pluginManager.getPlugins().values())) { if (!plugin.isEnabled() && type == plugin.getDescription().getOrder()) { this.enablePlugin(plugin); } } if (type == PluginLoadOrder.POSTWORLD) { this.commandMap.registerServerAliases(); DefaultPermissions.registerCorePermissions(); } }
Example #2
Source File: Server.java From Jupiter with GNU General Public License v3.0 | 5 votes |
/** * サーバーを再読み込みさせます。 * @return void */ public void reload() { this.logger.info("再読み込み中..."); this.logger.info("ワールドを保存しています..."); for (Level level : this.levels.values()) { level.save(); } this.pluginManager.disablePlugins(); this.pluginManager.clearPlugins(); this.commandMap.clearCommands(); this.logger.info("server.propertiesを再読み込みしています..."); this.properties.reload(); this.maxPlayers = this.getPropertyInt("max-players", 20); if (this.getPropertyBoolean("hardcore", false) && this.getDifficulty() < 3) { this.setPropertyInt("difficulty", 3); } this.banByIP.load(); this.banByName.load(); this.reloadWhitelist(); this.operators.reload(); for (BanEntry entry : this.getIPBans().getEntires().values()) { this.getNetwork().blockAddress(entry.getName(), -1); } this.pluginManager.registerInterface(JavaPluginLoader.class); this.pluginManager.loadPlugins(this.pluginPath); this.enablePlugins(PluginLoadOrder.STARTUP); this.enablePlugins(PluginLoadOrder.POSTWORLD); Timings.reset(); }
Example #3
Source File: Server.java From Nukkit with GNU General Public License v3.0 | 5 votes |
public void enablePlugins(PluginLoadOrder type) { for (Plugin plugin : new ArrayList<>(this.pluginManager.getPlugins().values())) { if (!plugin.isEnabled() && type == plugin.getDescription().getOrder()) { this.enablePlugin(plugin); } } if (type == PluginLoadOrder.POSTWORLD) { this.commandMap.registerServerAliases(); DefaultPermissions.registerCorePermissions(); } }
Example #4
Source File: Server.java From Nukkit with GNU General Public License v3.0 | 5 votes |
public void reload() { log.info("Reloading..."); log.info("Saving levels..."); for (Level level : this.levelArray) { level.save(); } this.pluginManager.disablePlugins(); this.pluginManager.clearPlugins(); this.commandMap.clearCommands(); log.info("Reloading properties..."); this.properties.reload(); this.maxPlayers = this.getPropertyInt("max-players", 20); if (this.getPropertyBoolean("hardcore", false) && this.getDifficulty() < 3) { this.setPropertyInt("difficulty", difficulty = 3); } this.banByIP.load(); this.banByName.load(); this.reloadWhitelist(); this.operators.reload(); for (BanEntry entry : this.getIPBans().getEntires().values()) { this.getNetwork().blockAddress(entry.getName(), -1); } this.pluginManager.registerInterface(JavaPluginLoader.class); this.pluginManager.loadPlugins(this.pluginPath); this.enablePlugins(PluginLoadOrder.STARTUP); this.enablePlugins(PluginLoadOrder.POSTWORLD); Timings.reset(); }
Example #5
Source File: Server.java From Nukkit with GNU General Public License v3.0 | 5 votes |
public void enablePlugins(PluginLoadOrder type) { for (Plugin plugin : new ArrayList<>(this.pluginManager.getPlugins().values())) { if (!plugin.isEnabled() && type == plugin.getDescription().getOrder()) { this.enablePlugin(plugin); } } if (type == PluginLoadOrder.POSTWORLD) { this.commandMap.registerServerAliases(); DefaultPermissions.registerCorePermissions(); } }
Example #6
Source File: Server.java From Nukkit with GNU General Public License v3.0 | 5 votes |
public void reload() { this.logger.info("Reloading..."); this.logger.info("Saving levels..."); for (Level level : this.levelArray) { level.save(); } this.pluginManager.disablePlugins(); this.pluginManager.clearPlugins(); this.commandMap.clearCommands(); this.logger.info("Reloading properties..."); this.properties.reload(); this.maxPlayers = this.getPropertyInt("max-players", 20); if (this.getPropertyBoolean("hardcore", false) && this.getDifficulty() < 3) { this.setPropertyInt("difficulty", difficulty = 3); } this.banByIP.load(); this.banByName.load(); this.reloadWhitelist(); this.operators.reload(); for (BanEntry entry : this.getIPBans().getEntires().values()) { this.getNetwork().blockAddress(entry.getName(), -1); } this.pluginManager.registerInterface(JavaPluginLoader.class); this.pluginManager.loadPlugins(this.pluginPath); this.enablePlugins(PluginLoadOrder.STARTUP); this.enablePlugins(PluginLoadOrder.POSTWORLD); Timings.reset(); }