@EventHandler
 public void onPluginDisable(PluginDisableEvent e) {
   if (!e.getPlugin().getName().equalsIgnoreCase("vault")) {
     return;
   }
   uninject(e.getPlugin());
 }
Beispiel #2
0
 @EventHandler(priority = EventPriority.MONITOR)
 public void onPluginDisable(PluginDisableEvent event) {
   if (economy.economy != null) {
     if (event.getPlugin().getDescription().getName().equals("BOSEconomy")
         && event.getPlugin().getDescription().getVersion().startsWith("0.6")) {
       economy.economy = null;
       log.info(
           String.format(
               "[%s][Economy] %s unhooked.", plugin.getDescription().getName(), economy.name));
     }
   }
 }
  @EventHandler(priority = EventPriority.NORMAL)
  public void onPluginDisable(PluginDisableEvent event) {
    ProtectionPlugins protectionPlugin;
    try {
      protectionPlugin = ProtectionPlugins.valueOf(event.getPlugin().getName());
    } catch (Exception e) {
      return;
    }

    this.instance.getLogger().info("Unloading protection plugin: " + event.getPlugin().getName());
    protectionPlugin.removeHandler();
  }
    @EventHandler
    public void onPluginDisable(PluginDisableEvent event) {
      String name = event.getPlugin().getDescription().getName();

      if (event.getPlugin() instanceof PermissionsProvider
          || "permissions".equalsIgnoreCase(name)
          || "permissionsex".equalsIgnoreCase(name)
          || "bpermissions".equalsIgnoreCase(name)
          || "groupmanager".equalsIgnoreCase(name)) {
        load();
      }
    }
 @EventHandler(priority = EventPriority.MONITOR)
 public void onPluginDisable(final PluginDisableEvent event) {
   if (event.getPlugin().getName().equals("EssentialsChat")) {
     ess.getSettings().setEssentialsChatActive(false);
   }
   ess.getAlternativeCommandsHandler().removePlugin(event.getPlugin());
   // Check to see if the plugin thats being disabled is the one we are using
   if (ess.getPaymentMethod() != null
       && Methods.hasMethod()
       && Methods.checkDisabled(event.getPlugin())) {
     Methods.reset();
     ess.getLogger().log(Level.INFO, "Payment method was disabled. No longer accepting payments.");
   }
 }
Beispiel #6
0
 @EventHandler
 public void onPluginDisable(PluginDisableEvent event) {
   if (event.getPlugin() == plugin) {
     despawnAll();
     Bukkit.getServer().getScheduler().cancelTask(taskid);
   }
 }
Beispiel #7
0
 @Override
 public void onPluginDisable(PluginDisableEvent event) {
   if (event.getPlugin().getDescription().getName().equals("iConomy")) {
     BetterShop.iConomy = null;
     iBank = null;
     Log(Level.WARNING, "iConomy has been disabled!");
   } else if (event.getPlugin().getDescription().getName().equals("BOSEconomy")) {
     BetterShop.economy = null;
     Log(Level.WARNING, "BOSEconomy has been disabled");
   } else if (event.getPlugin().getDescription().getName().equals("Permissions")) {
     BetterShop.Permissions = null;
     Log("Permissions support disabled");
   } else if (event.getPlugin().getDescription().getName().equals("MinecraftIM")) {
     messenger = null;
     Log("MinecraftIM link disabled");
   }
 }
Beispiel #8
0
 @EventHandler()
 public void onPluginDisable(PluginDisableEvent event) {
   if (eco.eco != null) {
     if (event.getPlugin().getDescription().getName().equals("iConomy")) {
       eco.eco = null;
       plugin.getLogger().log(Level.INFO, "Succesfully unhooked into iConomy 4!");
     }
   }
 }
Beispiel #9
0
 @EventHandler(priority = EventPriority.MONITOR)
 public void onPluginDisable(final PluginDisableEvent event) {
   if (plugin.iConomy != null) {
     if (event.getPlugin().getDescription().getName().equals("iConomy")) {
       plugin.iConomy = null;
       System.out.println("[MyPlugin] un-hooked from iConomy.");
     }
   }
 }
Beispiel #10
0
 public void onPluginDisable(PluginDisableEvent event) {
   if (this.chat.mChat != null) {
     if (event.getPlugin().getDescription().getName().equals("mChat")) {
       this.chat.mChat = null;
       log.info(
           String.format(
               "[%s][Chat] %s un-hooked.", plugin.getDescription().getName(), "mChat"));
     }
   }
 }
Beispiel #11
0
 @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);
   }
 }
 @EventHandler(priority = EventPriority.MONITOR)
 public void onPluginDisable(PluginDisableEvent event) {
   if (perms != null) {
     if (event.getPlugin().getDescription().getName().equals("Starburst")) {
       perms = null;
       log.info(
           String.format(
               "[%s][Permission] %s un-hooked.", plugin.getDescription().getName(), name));
     }
   }
 }
Beispiel #13
0
 @EventHandler(priority = EventPriority.MONITOR)
 public void onPluginDisable(PluginDisableEvent event) {
   if (mChat != null) {
     if (event.getPlugin().getDescription().getName().equals("mChatSuite")) {
       mChat = null;
       log.info(
           String.format(
               "[%s][Chat] %s un-hooked.", plugin.getDescription().getName(), "mChatSuite"));
     }
   }
 }
Beispiel #14
0
 // All of the below can be copy + pasted at will! No need to explain this, but:
 @Override
 public void onPluginDisable(PluginDisableEvent event) {
   // When the plugin is enabled and 3co isn't null, and the plugin that is disabled is 3co, say
   // that we are releasing it
   if (plugin.eco != null) {
     if (event.getPlugin().getDescription().getName().equals("3co")) {
       plugin.eco = null;
       System.out.println("[3coShop] 3co released!");
     }
   }
 }
 @EventHandler(priority = EventPriority.MONITOR)
 public void onPluginDisable(PluginDisableEvent event) {
   if ((this.permission.perms != null)
       && (event.getPlugin().getDescription().getName().equals("SimplyPerms"))) {
     this.permission.perms = null;
     Permission_SimplyPerms.log.info(
         String.format(
             "[%s][Permission] %s un-hooked.",
             new Object[] {
               Permission_SimplyPerms.this.plugin.getDescription().getName(), "SimplyPerms"
             }));
   }
 }
  @SuppressWarnings("static-access")
  @EventHandler(priority = EventPriority.MONITOR)
  public void onPluginDisable(PluginDisableEvent event) {
    // Check to see if the plugin thats being disabled is the one we are
    // using
    if (this.methods != null && this.methods.hasMethod()) {
      Boolean check = this.methods.checkDisabled(event.getPlugin());

      if (check) {
        EconomySupport.eco = null;
        Language.log_info("iconomyoff");
      }
    }
  }
  /**
   * Check for disabled plugin to remove the associated replacer
   *
   * @param disableEvent the disable event
   */
  @EventHandler
  public void onPluginDisable(PluginDisableEvent disableEvent) {
    // Remove the listener if the associated plugin was disabled
    final String disablePluginName = disableEvent.getPlugin().getName();

    final Map<String, VariableReplaceAdapter<? extends Plugin>> specificReplacers =
        replaceManager.getReplacers();
    final Iterator<VariableReplaceAdapter<? extends Plugin>> iterator =
        specificReplacers.values().iterator();
    while (iterator.hasNext()) {
      final Plugin plugin = iterator.next().getPlugin();
      if (plugin != null && plugin.getName().equals(disablePluginName)) {
        iterator.remove();
      }
    }
  }
 @EventHandler
 public void onPluginDisabled(PluginDisableEvent e) {
   onPluginDisabled(e.getPlugin());
 }