diff --git a/src/de/epiceric/shopchest/ShopChest.java b/src/de/epiceric/shopchest/ShopChest.java index 2a0c5d0..01c35d5 100644 --- a/src/de/epiceric/shopchest/ShopChest.java +++ b/src/de/epiceric/shopchest/ShopChest.java @@ -3,7 +3,7 @@ package de.epiceric.shopchest; import de.epiceric.shopchest.config.Config; import de.epiceric.shopchest.config.LanguageConfiguration; import de.epiceric.shopchest.config.Regex; -import de.epiceric.shopchest.event.*; +import de.epiceric.shopchest.listeners.*; import de.epiceric.shopchest.interfaces.JsonBuilder; import de.epiceric.shopchest.interfaces.jsonbuilder.*; import de.epiceric.shopchest.language.LanguageUtils; @@ -321,15 +321,15 @@ public class ShopChest extends JavaPlugin { initializeShops(); - getServer().getPluginManager().registerEvents(new UpdateHolograms(), this); - getServer().getPluginManager().registerEvents(new RegenerateShopItem(), this); - getServer().getPluginManager().registerEvents(new InteractShop(this), this); - getServer().getPluginManager().registerEvents(new NotifyUpdate(this), this); - getServer().getPluginManager().registerEvents(new ProtectChest(), this); + getServer().getPluginManager().registerEvents(new HologramUpdateListener(), this); + getServer().getPluginManager().registerEvents(new ItemProtectListener(), this); + getServer().getPluginManager().registerEvents(new ShopInteractListener(this), this); + getServer().getPluginManager().registerEvents(new NotifyUpdateOnJoinListener(this), this); + getServer().getPluginManager().registerEvents(new ChestProtectListener(), this); getServer().getPluginManager().registerEvents(new ItemCustomNameListener(), this); if (getServer().getPluginManager().getPlugin("ClearLag") != null) - getServer().getPluginManager().registerEvents(new RegenerateShopItemAfterRemove(), this); + getServer().getPluginManager().registerEvents(new ClearLagListener(), this); if (getServer().getPluginManager().getPlugin("LWC") != null) new LWCMagnetListener(this).initializeListener(); diff --git a/src/de/epiceric/shopchest/event/ProtectChest.java b/src/de/epiceric/shopchest/listeners/ChestProtectListener.java similarity index 97% rename from src/de/epiceric/shopchest/event/ProtectChest.java rename to src/de/epiceric/shopchest/listeners/ChestProtectListener.java index 28cafe0..f4b32bb 100644 --- a/src/de/epiceric/shopchest/event/ProtectChest.java +++ b/src/de/epiceric/shopchest/listeners/ChestProtectListener.java @@ -1,4 +1,4 @@ -package de.epiceric.shopchest.event; +package de.epiceric.shopchest.listeners; import de.epiceric.shopchest.ShopChest; import de.epiceric.shopchest.config.Config; @@ -23,7 +23,7 @@ import org.bukkit.inventory.InventoryHolder; import java.util.ArrayList; -public class ProtectChest implements Listener { +public class ChestProtectListener implements Listener { @EventHandler public void onBlockBreak(BlockBreakEvent e) { diff --git a/src/de/epiceric/shopchest/event/RegenerateShopItemAfterRemove.java b/src/de/epiceric/shopchest/listeners/ClearLagListener.java similarity index 85% rename from src/de/epiceric/shopchest/event/RegenerateShopItemAfterRemove.java rename to src/de/epiceric/shopchest/listeners/ClearLagListener.java index 7735789..e46a76a 100644 --- a/src/de/epiceric/shopchest/event/RegenerateShopItemAfterRemove.java +++ b/src/de/epiceric/shopchest/listeners/ClearLagListener.java @@ -1,4 +1,4 @@ -package de.epiceric.shopchest.event; +package de.epiceric.shopchest.listeners; import me.minebuilders.clearlag.events.EntityRemoveEvent; import org.bukkit.entity.Entity; @@ -8,7 +8,7 @@ import org.bukkit.event.Listener; import java.util.ArrayList; -public class RegenerateShopItemAfterRemove implements Listener { +public class ClearLagListener implements Listener { @EventHandler(priority = EventPriority.HIGH) public void onEntityRemove(EntityRemoveEvent e) { diff --git a/src/de/epiceric/shopchest/event/UpdateHolograms.java b/src/de/epiceric/shopchest/listeners/HologramUpdateListener.java similarity index 90% rename from src/de/epiceric/shopchest/event/UpdateHolograms.java rename to src/de/epiceric/shopchest/listeners/HologramUpdateListener.java index 9b28c82..e78e668 100644 --- a/src/de/epiceric/shopchest/event/UpdateHolograms.java +++ b/src/de/epiceric/shopchest/listeners/HologramUpdateListener.java @@ -1,4 +1,4 @@ -package de.epiceric.shopchest.event; +package de.epiceric.shopchest.listeners; import de.epiceric.shopchest.config.Config; import de.epiceric.shopchest.shop.Shop; @@ -9,9 +9,9 @@ import org.bukkit.event.EventHandler; import org.bukkit.event.Listener; import org.bukkit.event.player.PlayerMoveEvent; -public class UpdateHolograms implements Listener { +public class HologramUpdateListener implements Listener { - public UpdateHolograms() { + public HologramUpdateListener() { } @EventHandler diff --git a/src/de/epiceric/shopchest/event/ItemCustomNameListener.java b/src/de/epiceric/shopchest/listeners/ItemCustomNameListener.java similarity index 91% rename from src/de/epiceric/shopchest/event/ItemCustomNameListener.java rename to src/de/epiceric/shopchest/listeners/ItemCustomNameListener.java index 73ebf8f..f548bfb 100644 --- a/src/de/epiceric/shopchest/event/ItemCustomNameListener.java +++ b/src/de/epiceric/shopchest/listeners/ItemCustomNameListener.java @@ -1,4 +1,4 @@ -package de.epiceric.shopchest.event; +package de.epiceric.shopchest.listeners; import org.bukkit.event.EventHandler; import org.bukkit.event.EventPriority; diff --git a/src/de/epiceric/shopchest/event/RegenerateShopItem.java b/src/de/epiceric/shopchest/listeners/ItemProtectListener.java similarity index 88% rename from src/de/epiceric/shopchest/event/RegenerateShopItem.java rename to src/de/epiceric/shopchest/listeners/ItemProtectListener.java index f17067f..5502ee3 100644 --- a/src/de/epiceric/shopchest/event/RegenerateShopItem.java +++ b/src/de/epiceric/shopchest/listeners/ItemProtectListener.java @@ -1,4 +1,4 @@ -package de.epiceric.shopchest.event; +package de.epiceric.shopchest.listeners; import org.bukkit.entity.Item; @@ -10,10 +10,7 @@ import org.bukkit.event.inventory.InventoryPickupItemEvent; import org.bukkit.event.inventory.InventoryType; import org.bukkit.event.player.PlayerPickupItemEvent; -public class RegenerateShopItem implements Listener { - - public RegenerateShopItem() { - } +public class ItemProtectListener implements Listener { @EventHandler(priority = EventPriority.HIGH) public void onItemDespawn(ItemDespawnEvent e) { diff --git a/src/de/epiceric/shopchest/event/LWCMagnetListener.java b/src/de/epiceric/shopchest/listeners/LWCMagnetListener.java similarity index 96% rename from src/de/epiceric/shopchest/event/LWCMagnetListener.java rename to src/de/epiceric/shopchest/listeners/LWCMagnetListener.java index 7f2a3f6..6b33d6c 100644 --- a/src/de/epiceric/shopchest/event/LWCMagnetListener.java +++ b/src/de/epiceric/shopchest/listeners/LWCMagnetListener.java @@ -1,4 +1,4 @@ -package de.epiceric.shopchest.event; +package de.epiceric.shopchest.listeners; import com.griefcraft.lwc.LWC; import com.griefcraft.scripting.JavaModule; diff --git a/src/de/epiceric/shopchest/event/NotifyUpdate.java b/src/de/epiceric/shopchest/listeners/NotifyUpdateOnJoinListener.java similarity index 94% rename from src/de/epiceric/shopchest/event/NotifyUpdate.java rename to src/de/epiceric/shopchest/listeners/NotifyUpdateOnJoinListener.java index 56a1ff1..de72f68 100644 --- a/src/de/epiceric/shopchest/event/NotifyUpdate.java +++ b/src/de/epiceric/shopchest/listeners/NotifyUpdateOnJoinListener.java @@ -1,4 +1,4 @@ -package de.epiceric.shopchest.event; +package de.epiceric.shopchest.listeners; import de.epiceric.shopchest.ShopChest; import de.epiceric.shopchest.config.Regex; @@ -13,12 +13,12 @@ import org.bukkit.event.EventHandler; import org.bukkit.event.Listener; import org.bukkit.event.player.PlayerJoinEvent; -public class NotifyUpdate implements Listener { +public class NotifyUpdateOnJoinListener implements Listener { private ShopChest plugin; private Permission perm; - public NotifyUpdate(ShopChest plugin) { + public NotifyUpdateOnJoinListener(ShopChest plugin) { this.plugin = plugin; perm = plugin.getPermission(); } diff --git a/src/de/epiceric/shopchest/event/InteractShop.java b/src/de/epiceric/shopchest/listeners/ShopInteractListener.java similarity index 99% rename from src/de/epiceric/shopchest/event/InteractShop.java rename to src/de/epiceric/shopchest/listeners/ShopInteractListener.java index 65a6517..6c25753 100644 --- a/src/de/epiceric/shopchest/event/InteractShop.java +++ b/src/de/epiceric/shopchest/listeners/ShopInteractListener.java @@ -1,4 +1,4 @@ -package de.epiceric.shopchest.event; +package de.epiceric.shopchest.listeners; import com.griefcraft.lwc.LWC; import com.griefcraft.model.Protection; @@ -36,14 +36,14 @@ import org.yi.acru.bukkit.Lockette.Lockette; import java.util.HashMap; import java.util.Map; -public class InteractShop implements Listener { +public class ShopInteractListener implements Listener { private ShopChest plugin; private Permission perm; private Economy econ; private Database database; - public InteractShop(ShopChest plugin) { + public ShopInteractListener(ShopChest plugin) { this.plugin = plugin; this.perm = plugin.getPermission(); this.econ = plugin.getEconomy();