From b66f1a0735f05a8a9dd1db4e22a08b65da02303b Mon Sep 17 00:00:00 2001 From: alisolarflare Date: Mon, 21 Nov 2016 13:32:46 -0500 Subject: [PATCH] Adjusted Potato usage to reflect API change --- src/alisolarflare/AliPresents.java | 2 ++ .../components/bankchest/BankChestComponent.java | 15 +++++++++++++++ .../components/bankchest/BankChestListener.java | 6 ++++++ .../components/bankchest/CreateBankChest.java | 15 +++++++++++++++ .../metrics/listeners/PlayerJoinListener.java | 5 ++--- 5 files changed, 40 insertions(+), 3 deletions(-) create mode 100644 src/alisolarflare/components/bankchest/BankChestComponent.java create mode 100644 src/alisolarflare/components/bankchest/BankChestListener.java create mode 100644 src/alisolarflare/components/bankchest/CreateBankChest.java diff --git a/src/alisolarflare/AliPresents.java b/src/alisolarflare/AliPresents.java index f895dfc..bc334b6 100644 --- a/src/alisolarflare/AliPresents.java +++ b/src/alisolarflare/AliPresents.java @@ -7,6 +7,7 @@ import org.bukkit.plugin.PluginDescriptionFile; import org.bukkit.plugin.java.JavaPlugin; import alisolarflare.components.alilinks.AliLinkComponent; +import alisolarflare.components.bankchest.BankChestComponent; import alisolarflare.components.creativeboundaries.CreativeBoundariesComponent; import alisolarflare.components.easyuhc.EasyUHCComponent; import alisolarflare.components.flairdoor.FlairDoorComponent; @@ -25,6 +26,7 @@ public class AliPresents extends JavaPlugin{ new AliLinkComponent().register(this); + new BankChestComponent().register(this); new CreativeBoundariesComponent().register(this); new EasyUHCComponent().register(this); new FlairDoorComponent().register(this); diff --git a/src/alisolarflare/components/bankchest/BankChestComponent.java b/src/alisolarflare/components/bankchest/BankChestComponent.java new file mode 100644 index 0000000..0fe9ea6 --- /dev/null +++ b/src/alisolarflare/components/bankchest/BankChestComponent.java @@ -0,0 +1,15 @@ +package alisolarflare.components.bankchest; + +import org.bukkit.plugin.java.JavaPlugin; + +import alisolarflare.components.Component; + +public class BankChestComponent extends Component { + + @Override + public void register(JavaPlugin plugin) { + registerCommand(plugin, new CreateBankChest()); + registerListener(plugin, new BankChestListener()); + } + +} diff --git a/src/alisolarflare/components/bankchest/BankChestListener.java b/src/alisolarflare/components/bankchest/BankChestListener.java new file mode 100644 index 0000000..d413bad --- /dev/null +++ b/src/alisolarflare/components/bankchest/BankChestListener.java @@ -0,0 +1,6 @@ +package alisolarflare.components.bankchest; + +import org.bukkit.event.Listener; + +public class BankChestListener implements Listener { +} diff --git a/src/alisolarflare/components/bankchest/CreateBankChest.java b/src/alisolarflare/components/bankchest/CreateBankChest.java new file mode 100644 index 0000000..deb1c9a --- /dev/null +++ b/src/alisolarflare/components/bankchest/CreateBankChest.java @@ -0,0 +1,15 @@ +package alisolarflare.components.bankchest; + +import org.bukkit.command.CommandSender; + +import alisolarflare.components.ModCommand; + +public class CreateBankChest extends ModCommand { + + @Override + public boolean OnCommand(CommandSender sender, String alias, String[] args) { + // TODO Auto-generated method stub + return false; + } + +} diff --git a/src/alisolarflare/components/metrics/listeners/PlayerJoinListener.java b/src/alisolarflare/components/metrics/listeners/PlayerJoinListener.java index c457618..83ce00a 100644 --- a/src/alisolarflare/components/metrics/listeners/PlayerJoinListener.java +++ b/src/alisolarflare/components/metrics/listeners/PlayerJoinListener.java @@ -6,7 +6,6 @@ import org.bukkit.event.player.PlayerJoinEvent; import alisolarflare.components.metrics.MetricsComponent; import buttondevteam.lib.DebugPotato; -import buttondevteam.lib.DebugPotatoAPI; public class PlayerJoinListener implements Listener{ @@ -26,11 +25,11 @@ public class PlayerJoinListener implements Listener{ "Time: " + System.currentTimeMillis(), "MetricsYML: " + module.metricsYml.toString() }); - DebugPotatoAPI.SendDebugPotato(potato, event.getPlayer()); + potato.Send(event.getPlayer()); }catch (Exception ex){ DebugPotato potato = new DebugPotato(); potato.setMessage("Something went REALLLY wrong"); - DebugPotatoAPI.SendDebugPotato(potato, event.getPlayer()); + potato.Send(event.getPlayer()); } } module.metricsList.add("loginlog."+System.currentTimeMillis()+event.getPlayer().getName());