From 619377c72f737139d12fb97be0de07b183f067b8 Mon Sep 17 00:00:00 2001 From: bobby29831 Date: Fri, 13 May 2022 11:18:09 -0500 Subject: refactor: optimize imports --- src/main/java/net/tylermurphy/hideAndSeek/command/Help.java | 3 +-- src/main/java/net/tylermurphy/hideAndSeek/command/Join.java | 5 ++--- src/main/java/net/tylermurphy/hideAndSeek/command/Leave.java | 7 ++----- src/main/java/net/tylermurphy/hideAndSeek/command/Reload.java | 11 +++++------ .../java/net/tylermurphy/hideAndSeek/command/SaveMap.java | 7 +++---- .../java/net/tylermurphy/hideAndSeek/command/SetBorder.java | 5 ++--- .../java/net/tylermurphy/hideAndSeek/command/SetBounds.java | 5 ++--- .../net/tylermurphy/hideAndSeek/command/SetExitLocation.java | 5 ++--- .../net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java | 5 ++--- .../net/tylermurphy/hideAndSeek/command/SetSpawnLocation.java | 6 ++---- src/main/java/net/tylermurphy/hideAndSeek/command/Setup.java | 7 +++---- src/main/java/net/tylermurphy/hideAndSeek/command/Start.java | 11 +++++------ src/main/java/net/tylermurphy/hideAndSeek/command/Stop.java | 6 +++--- src/main/java/net/tylermurphy/hideAndSeek/command/Top.java | 4 ++-- src/main/java/net/tylermurphy/hideAndSeek/command/Wins.java | 4 ++-- 15 files changed, 38 insertions(+), 53 deletions(-) (limited to 'src/main/java/net/tylermurphy/hideAndSeek/command') diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/Help.java b/src/main/java/net/tylermurphy/hideAndSeek/command/Help.java index c1934a9..d773e60 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/Help.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/Help.java @@ -19,10 +19,9 @@ package net.tylermurphy.hideAndSeek.command; -import org.bukkit.command.CommandSender; - import net.md_5.bungee.api.ChatColor; import net.tylermurphy.hideAndSeek.game.CommandHandler; +import org.bukkit.command.CommandSender; public class Help implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/Join.java b/src/main/java/net/tylermurphy/hideAndSeek/command/Join.java index 0ca21d1..025ec7f 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/Join.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/Join.java @@ -19,15 +19,14 @@ package net.tylermurphy.hideAndSeek.command; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; - import net.tylermurphy.hideAndSeek.game.Board; import net.tylermurphy.hideAndSeek.game.Game; import org.bukkit.Bukkit; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.errorPrefix; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class Join implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/Leave.java b/src/main/java/net/tylermurphy/hideAndSeek/command/Leave.java index 8d8cf76..c625fdc 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/Leave.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/Leave.java @@ -19,17 +19,14 @@ package net.tylermurphy.hideAndSeek.command; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; - import net.tylermurphy.hideAndSeek.game.Board; import net.tylermurphy.hideAndSeek.game.Game; -import net.tylermurphy.hideAndSeek.util.Status; import org.bukkit.Bukkit; -import org.bukkit.Location; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.errorPrefix; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class Leave implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/Reload.java b/src/main/java/net/tylermurphy/hideAndSeek/command/Reload.java index fc2592b..1ec2c71 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/Reload.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/Reload.java @@ -19,17 +19,16 @@ package net.tylermurphy.hideAndSeek.command; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; - +import net.tylermurphy.hideAndSeek.configuration.Config; import net.tylermurphy.hideAndSeek.configuration.Items; +import net.tylermurphy.hideAndSeek.configuration.Localization; import net.tylermurphy.hideAndSeek.game.Game; import net.tylermurphy.hideAndSeek.util.Status; import org.bukkit.command.CommandSender; -import net.tylermurphy.hideAndSeek.configuration.Config; -import net.tylermurphy.hideAndSeek.configuration.Localization; - -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.errorPrefix; +import static net.tylermurphy.hideAndSeek.configuration.Config.messagePrefix; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class Reload implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/SaveMap.java b/src/main/java/net/tylermurphy/hideAndSeek/command/SaveMap.java index f5e63a5..e9f1cc8 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/SaveMap.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/SaveMap.java @@ -19,8 +19,7 @@ package net.tylermurphy.hideAndSeek.command; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; - +import net.tylermurphy.hideAndSeek.Main; import net.tylermurphy.hideAndSeek.game.Game; import net.tylermurphy.hideAndSeek.util.Status; import org.bukkit.Bukkit; @@ -28,8 +27,8 @@ import org.bukkit.World; import org.bukkit.command.CommandSender; import org.bukkit.scheduler.BukkitRunnable; -import net.tylermurphy.hideAndSeek.Main; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.*; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class SaveMap implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/SetBorder.java b/src/main/java/net/tylermurphy/hideAndSeek/command/SetBorder.java index 798b99f..11ff225 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/SetBorder.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/SetBorder.java @@ -19,15 +19,14 @@ package net.tylermurphy.hideAndSeek.command; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; - import net.tylermurphy.hideAndSeek.game.Game; import net.tylermurphy.hideAndSeek.util.Status; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; import org.bukkit.util.Vector; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.*; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class SetBorder implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/SetBounds.java b/src/main/java/net/tylermurphy/hideAndSeek/command/SetBounds.java index 9f4101a..f369f29 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/SetBounds.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/SetBounds.java @@ -19,14 +19,13 @@ package net.tylermurphy.hideAndSeek.command; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; - import net.tylermurphy.hideAndSeek.game.Game; import net.tylermurphy.hideAndSeek.util.Status; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.*; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class SetBounds implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java b/src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java index 7461767..e54fde6 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java @@ -19,8 +19,6 @@ package net.tylermurphy.hideAndSeek.command; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; - import net.tylermurphy.hideAndSeek.game.Game; import net.tylermurphy.hideAndSeek.util.Status; import org.bukkit.World; @@ -28,7 +26,8 @@ import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; import org.bukkit.util.Vector; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.*; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class SetExitLocation implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java b/src/main/java/net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java index 69e5e52..bdd8aad 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java @@ -19,8 +19,6 @@ package net.tylermurphy.hideAndSeek.command; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; - import net.tylermurphy.hideAndSeek.game.Game; import net.tylermurphy.hideAndSeek.util.Status; import org.bukkit.World; @@ -28,7 +26,8 @@ import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; import org.bukkit.util.Vector; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.*; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class SetLobbyLocation implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/SetSpawnLocation.java b/src/main/java/net/tylermurphy/hideAndSeek/command/SetSpawnLocation.java index d5e1cba..83e0145 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/SetSpawnLocation.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/SetSpawnLocation.java @@ -19,8 +19,6 @@ package net.tylermurphy.hideAndSeek.command; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; - import net.tylermurphy.hideAndSeek.game.Game; import net.tylermurphy.hideAndSeek.util.Status; import net.tylermurphy.hideAndSeek.world.WorldLoader; @@ -29,8 +27,8 @@ import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; import org.bukkit.util.Vector; -import static net.tylermurphy.hideAndSeek.configuration.Config.addToConfig; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.*; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class SetSpawnLocation implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/Setup.java b/src/main/java/net/tylermurphy/hideAndSeek/command/Setup.java index 14a5d6f..af06e0b 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/Setup.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/Setup.java @@ -19,15 +19,14 @@ package net.tylermurphy.hideAndSeek.command; +import net.tylermurphy.hideAndSeek.Main; import net.tylermurphy.hideAndSeek.game.Game; import org.bukkit.command.CommandSender; -import net.tylermurphy.hideAndSeek.Main; +import java.io.File; import static net.tylermurphy.hideAndSeek.configuration.Config.*; - -import java.io.File; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class Setup implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/Start.java b/src/main/java/net/tylermurphy/hideAndSeek/command/Start.java index 8605764..bab9c5f 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/Start.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/Start.java @@ -19,8 +19,7 @@ package net.tylermurphy.hideAndSeek.command; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; - +import net.tylermurphy.hideAndSeek.Main; import net.tylermurphy.hideAndSeek.game.Board; import net.tylermurphy.hideAndSeek.game.Game; import net.tylermurphy.hideAndSeek.util.Status; @@ -28,13 +27,13 @@ import org.bukkit.Bukkit; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -import net.tylermurphy.hideAndSeek.Main; - -import static net.tylermurphy.hideAndSeek.configuration.Config.*; - import java.util.Optional; import java.util.Random; +import static net.tylermurphy.hideAndSeek.configuration.Config.errorPrefix; +import static net.tylermurphy.hideAndSeek.configuration.Config.minPlayers; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; + public class Start implements ICommand { public void execute(CommandSender sender, String[] args) { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/Stop.java b/src/main/java/net/tylermurphy/hideAndSeek/command/Stop.java index efbbfac..37130d0 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/Stop.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/Stop.java @@ -19,13 +19,13 @@ package net.tylermurphy.hideAndSeek.command; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; - import net.tylermurphy.hideAndSeek.game.Game; import net.tylermurphy.hideAndSeek.util.Status; import org.bukkit.command.CommandSender; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.abortPrefix; +import static net.tylermurphy.hideAndSeek.configuration.Config.errorPrefix; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class Stop implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/Top.java b/src/main/java/net/tylermurphy/hideAndSeek/command/Top.java index 51e3574..d362bba 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/Top.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/Top.java @@ -27,8 +27,8 @@ import org.bukkit.command.CommandSender; import java.util.List; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.errorPrefix; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class Top implements ICommand { diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/Wins.java b/src/main/java/net/tylermurphy/hideAndSeek/command/Wins.java index 9140f49..feed663 100644 --- a/src/main/java/net/tylermurphy/hideAndSeek/command/Wins.java +++ b/src/main/java/net/tylermurphy/hideAndSeek/command/Wins.java @@ -29,8 +29,8 @@ import org.bukkit.entity.Player; import java.util.UUID; -import static net.tylermurphy.hideAndSeek.configuration.Config.*; -import static net.tylermurphy.hideAndSeek.configuration.Localization.*; +import static net.tylermurphy.hideAndSeek.configuration.Config.errorPrefix; +import static net.tylermurphy.hideAndSeek.configuration.Localization.message; public class Wins implements ICommand { -- cgit v1.2.3-freya