@Override public void onPluginDisable(PluginDisableEvent event) { if (this.methods != null && this.methods.hasMethod()) { Boolean check = this.methods.checkDisabled(event.getPlugin()); if (check) { Messaging.log("Payment method disabled."); } EconomyManager.setServerEconomyEnabled(false); } }
@Override public void onPluginEnable(PluginEnableEvent event) { if (!this.methods.hasMethod()) { if (this.methods.setMethod(event.getPlugin())) { Citizens.setMethod(this.methods.getMethod()); EconomyManager.setServerEconomyEnabled(true); Messaging.log( "Payment method found (" + methods.getMethod().getName() + " version: " + methods.getMethod().getVersion() + ")"); } } }