mirror of
https://github.com/Auxilor/EcoEnchants.git
synced 2024-11-25 15:35:11 +01:00
Fixed essentials integrations
This commit is contained in:
parent
08946c6233
commit
1e8b77bd2b
@ -316,7 +316,6 @@ public class EcoEnchants {
|
|||||||
for (EcoEnchant ecoEnchant : new HashSet<>(getAll())) {
|
for (EcoEnchant ecoEnchant : new HashSet<>(getAll())) {
|
||||||
ecoEnchant.update();
|
ecoEnchant.update();
|
||||||
}
|
}
|
||||||
EssentialsManager.registerEnchantments();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -6,7 +6,7 @@ import java.util.Set;
|
|||||||
public class EssentialsManager {
|
public class EssentialsManager {
|
||||||
private static final Set<EssentialsWrapper> registered = new HashSet<>();
|
private static final Set<EssentialsWrapper> registered = new HashSet<>();
|
||||||
|
|
||||||
public static void registerAntigrief(EssentialsWrapper essentials) {
|
public static void registerEssentials(EssentialsWrapper essentials) {
|
||||||
registered.add(essentials);
|
registered.add(essentials);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -26,6 +26,8 @@ import com.willfp.ecoenchants.grindstone.GrindstoneListeners;
|
|||||||
import com.willfp.ecoenchants.integrations.anticheat.AnticheatManager;
|
import com.willfp.ecoenchants.integrations.anticheat.AnticheatManager;
|
||||||
import com.willfp.ecoenchants.integrations.anticheat.plugins.AnticheatAAC;
|
import com.willfp.ecoenchants.integrations.anticheat.plugins.AnticheatAAC;
|
||||||
import com.willfp.ecoenchants.integrations.anticheat.plugins.AnticheatMatrix;
|
import com.willfp.ecoenchants.integrations.anticheat.plugins.AnticheatMatrix;
|
||||||
|
import com.willfp.ecoenchants.integrations.anticheat.plugins.AnticheatNCP;
|
||||||
|
import com.willfp.ecoenchants.integrations.anticheat.plugins.AnticheatSpartan;
|
||||||
import com.willfp.ecoenchants.integrations.antigrief.AntigriefManager;
|
import com.willfp.ecoenchants.integrations.antigrief.AntigriefManager;
|
||||||
import com.willfp.ecoenchants.integrations.antigrief.plugins.*;
|
import com.willfp.ecoenchants.integrations.antigrief.plugins.*;
|
||||||
import com.willfp.ecoenchants.integrations.essentials.EssentialsManager;
|
import com.willfp.ecoenchants.integrations.essentials.EssentialsManager;
|
||||||
@ -155,7 +157,7 @@ public class Loader {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(Bukkit.getPluginManager().isPluginEnabled("Essentials")) {
|
if(Bukkit.getPluginManager().isPluginEnabled("Essentials")) {
|
||||||
EssentialsManager.registerAntigrief(new IntegrationEssentials());
|
EssentialsManager.registerEssentials(new IntegrationEssentials());
|
||||||
Logger.info("Essentials: §aENABLED");
|
Logger.info("Essentials: §aENABLED");
|
||||||
} else {
|
} else {
|
||||||
Logger.info("Essentials: §9DISABLED");
|
Logger.info("Essentials: §9DISABLED");
|
||||||
@ -176,14 +178,14 @@ public class Loader {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if(Bukkit.getPluginManager().isPluginEnabled("NoCheatPlus")) {
|
if(Bukkit.getPluginManager().isPluginEnabled("NoCheatPlus")) {
|
||||||
AnticheatManager.registerAnticheat(new AnticheatAAC());
|
AnticheatManager.registerAnticheat(new AnticheatNCP());
|
||||||
Logger.info("NCP: §aENABLED");
|
Logger.info("NCP: §aENABLED");
|
||||||
} else {
|
} else {
|
||||||
Logger.info("NCP: §9DISABLED");
|
Logger.info("NCP: §9DISABLED");
|
||||||
}
|
}
|
||||||
|
|
||||||
if(Bukkit.getPluginManager().isPluginEnabled("Spartan")) {
|
if(Bukkit.getPluginManager().isPluginEnabled("Spartan")) {
|
||||||
AnticheatManager.registerAnticheat(new AnticheatAAC());
|
AnticheatManager.registerAnticheat(new AnticheatSpartan());
|
||||||
Logger.info("Spartan: §aENABLED");
|
Logger.info("Spartan: §aENABLED");
|
||||||
} else {
|
} else {
|
||||||
Logger.info("Spartan: §9DISABLED");
|
Logger.info("Spartan: §9DISABLED");
|
||||||
@ -313,6 +315,7 @@ public class Loader {
|
|||||||
Bukkit.getPluginManager().disablePlugin(EcoEnchantsPlugin.getInstance());
|
Bukkit.getPluginManager().disablePlugin(EcoEnchantsPlugin.getInstance());
|
||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
|
EssentialsManager.registerEnchantments();
|
||||||
Logger.info(EcoEnchants.getAll().size() + " Enchantments Loaded:");
|
Logger.info(EcoEnchants.getAll().size() + " Enchantments Loaded:");
|
||||||
EcoEnchants.getAll().forEach((ecoEnchant -> {
|
EcoEnchants.getAll().forEach((ecoEnchant -> {
|
||||||
if(ecoEnchant.getType().equals(EcoEnchant.EnchantmentType.SPECIAL)) {
|
if(ecoEnchant.getType().equals(EcoEnchant.EnchantmentType.SPECIAL)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user