Economy integration now works for EssentialsEco as well
This commit is contained in:
@ -146,6 +146,7 @@ public class Factions extends JavaPlugin {
|
||||
|
||||
setupPermissions();
|
||||
integrateEssentialsChat();
|
||||
setupEcon();
|
||||
|
||||
Econ.monitorPlugins();
|
||||
|
||||
@ -212,6 +213,25 @@ public class Factions extends JavaPlugin {
|
||||
Factions.log("Permissions plugin not detected, defaulting to Bukkit superperms system");
|
||||
}
|
||||
}
|
||||
|
||||
private void setupEcon() {
|
||||
if (Econ.enabled()) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (!Econ.iConomyHooked()) {
|
||||
Plugin plug = this.getServer().getPluginManager().getPlugin("iConomy");
|
||||
if (plug != null && plug.getClass().getName().equals("com.iConomy.iConomy")) {
|
||||
Econ.iConomySet(true);
|
||||
}
|
||||
}
|
||||
if (!Econ.essentialsEcoHooked()) {
|
||||
Plugin plug = this.getServer().getPluginManager().getPlugin("Essentials");
|
||||
if (plug != null) {
|
||||
Econ.essentialsEcoSet(true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void integrateEssentialsChat() {
|
||||
if (essChat != null) {
|
||||
|
Reference in New Issue
Block a user