use of net.dzikoysk.funnyguilds.listener.dynamic.DynamicListenerManager in project FunnyGuilds by FunnyGuilds.
the class FunnyGuilds method onLoad.
@Override
public void onLoad() {
plugin = this;
logger = new FunnyGuildsLogger(this);
this.version = new FunnyGuildsVersion(this);
try {
Class.forName("net.md_5.bungee.api.ChatColor");
} catch (Exception spigotNeeded) {
logger.error("FunnyGuilds requires spigot to work, your server seems to be using something else");
logger.error("If you think that is not true - contact plugin developers");
logger.error("https://github.com/FunnyGuilds/FunnyGuilds");
shutdown("Spigot required for service not detected!");
return;
}
if (!this.getDataFolder().exists()) {
this.getDataFolder().mkdir();
}
this.nmsAccessor = this.prepareNmsAccessor();
try {
ConfigurationFactory configurationFactory = new ConfigurationFactory();
this.messageConfiguration = configurationFactory.createMessageConfiguration(messageConfigurationFile);
this.pluginConfiguration = configurationFactory.createPluginConfiguration(pluginConfigurationFile);
this.tablistConfiguration = configurationFactory.createTablistConfiguration(tablistConfigurationFile);
} catch (Exception exception) {
logger.error("Could not load plugin configuration", exception);
shutdown("Critical error has been encountered!");
return;
}
DescriptionChanger descriptionChanger = new DescriptionChanger(super.getDescription());
descriptionChanger.rename(pluginConfiguration.pluginName);
this.concurrencyManager = new ConcurrencyManager(this, pluginConfiguration.concurrencyThreads);
this.concurrencyManager.printStatus();
this.dynamicListenerManager = new DynamicListenerManager(this);
this.hookManager = new HookManager(plugin);
this.hookManager.setupEarlyHooks();
this.hookManager.earlyInit();
}
Aggregations