summaryrefslogtreewikicommitdiff
path: root/src/main/java/net/tylermurphy/hideAndSeek/command/Reload.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/net/tylermurphy/hideAndSeek/command/Reload.java')
-rw-r--r--src/main/java/net/tylermurphy/hideAndSeek/command/Reload.java33
1 files changed, 33 insertions, 0 deletions
diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/Reload.java b/src/main/java/net/tylermurphy/hideAndSeek/command/Reload.java
new file mode 100644
index 0000000..1b1f1d5
--- /dev/null
+++ b/src/main/java/net/tylermurphy/hideAndSeek/command/Reload.java
@@ -0,0 +1,33 @@
+package net.tylermurphy.hideAndSeek.command;
+
+import org.bukkit.command.CommandSender;
+
+import net.tylermurphy.hideAndSeek.Store;
+import net.tylermurphy.hideAndSeek.util.Functions;
+import net.tylermurphy.hideAndSeek.util.ICommand;
+
+import static net.tylermurphy.hideAndSeek.Store.*;
+
+public class Reload implements ICommand {
+
+ public void execute(CommandSender sender, String[] args) {
+ Store.loadConfig();
+ try {
+ Functions.loadScoreboard();
+ } catch(Exception e) {}
+ sender.sendMessage(messagePrefix + "Reloaded the config");
+ }
+
+ public String getLabel() {
+ return "reload";
+ }
+
+ public String getUsage() {
+ return "";
+ }
+
+ public String getDescription() {
+ return "Reloads the config";
+ }
+
+}