From e4ac71e8fffc141cb4a1c6fdca7f5604e9a30684 Mon Sep 17 00:00:00 2001 From: Brianna Date: Fri, 11 Oct 2019 13:24:52 -0400 Subject: [PATCH] Fixed issue with tokens not working. --- src/main/java/com/songoda/epicheads/EpicHeads.java | 3 ++- src/main/java/com/songoda/epicheads/settings/Settings.java | 2 +- src/main/java/com/songoda/epicheads/utils/ItemEconomy.java | 5 ++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main/java/com/songoda/epicheads/EpicHeads.java b/src/main/java/com/songoda/epicheads/EpicHeads.java index eda9f0f..6c5daf2 100644 --- a/src/main/java/com/songoda/epicheads/EpicHeads.java +++ b/src/main/java/com/songoda/epicheads/EpicHeads.java @@ -44,7 +44,7 @@ public class EpicHeads extends SongodaPlugin { private HeadManager headManager; private PlayerManager playerManager; private CommandManager commandManager; - PluginHook itemEconomyHook = PluginHook.addHook(Economy.class, "EpicHeads", com.songoda.epicheads.economy.ItemEconomy.class); + private PluginHook itemEconomyHook; private Storage storage; @@ -55,6 +55,7 @@ public class EpicHeads extends SongodaPlugin { @Override public void onPluginLoad() { INSTANCE = this; + this.itemEconomyHook = PluginHook.addHook(Economy.class, "EpicHeads", com.songoda.epicheads.utils.ItemEconomy.class); } @Override diff --git a/src/main/java/com/songoda/epicheads/settings/Settings.java b/src/main/java/com/songoda/epicheads/settings/Settings.java index 49b9331..d7c3fc3 100644 --- a/src/main/java/com/songoda/epicheads/settings/Settings.java +++ b/src/main/java/com/songoda/epicheads/settings/Settings.java @@ -49,7 +49,7 @@ public class Settings { public static final ConfigSetting ECONOMY_PLUGIN = new ConfigSetting(config, "Economy.Economy", EconomyManager.getEconomy() == null ? "Vault" : EconomyManager.getEconomy().getName(), "Which economy plugin should be used?", - "Supported plugins you have installed: \"" + EconomyManager.getManager().getRegisteredPlugins().stream().collect(Collectors.joining("\", \"")) + "\"."); + "Supported plugins you have installed: \"" + EconomyManager.getManager().getRegisteredPlugins().stream().filter(p -> !p.equals("EpicHeads")).collect(Collectors.joining("\", \"")) + "\", \"Item\"."); public static final ConfigSetting HEAD_COST = new ConfigSetting(config, "Economy.Head Cost", 24.99, "The cost the of the head. If you wan't to use PlayerPoints", diff --git a/src/main/java/com/songoda/epicheads/utils/ItemEconomy.java b/src/main/java/com/songoda/epicheads/utils/ItemEconomy.java index ba06178..73d93d9 100644 --- a/src/main/java/com/songoda/epicheads/utils/ItemEconomy.java +++ b/src/main/java/com/songoda/epicheads/utils/ItemEconomy.java @@ -1,7 +1,6 @@ -package com.songoda.epicheads.economy; +package com.songoda.epicheads.utils; import com.songoda.core.hooks.economies.Economy; -import com.songoda.epicheads.utils.Methods; import org.bukkit.OfflinePlayer; import org.bukkit.inventory.ItemStack; @@ -68,6 +67,6 @@ public class ItemEconomy extends Economy { @Override public boolean isEnabled() { - return false; + return true; } }