summaryrefslogtreewikicommitdiff
path: root/src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java
diff options
context:
space:
mode:
authorbobby29831 <bobby29831@gmail.com>2022-05-13 12:01:31 -0500
committerbobby29831 <bobby29831@gmail.com>2022-05-13 12:01:31 -0500
commit2f4ca0d0f949f38f1d4c1512edeb9b32b80171f7 (patch)
treeb2ee6a9f40f2b0bf997b933b75a220d728a2f354 /src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java
parentrefactor: break apart over saturated EventListener.java (diff)
downloadkenshinshideandseek-2f4ca0d0f949f38f1d4c1512edeb9b32b80171f7.tar.gz
kenshinshideandseek-2f4ca0d0f949f38f1d4c1512edeb9b32b80171f7.tar.bz2
kenshinshideandseek-2f4ca0d0f949f38f1d4c1512edeb9b32b80171f7.zip
refactor: general improvements, fix spacing inconsistencies
Diffstat (limited to 'src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java')
-rw-r--r--src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java b/src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java
index e54fde6..de33b93 100644
--- a/src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java
+++ b/src/main/java/net/tylermurphy/hideAndSeek/command/SetExitLocation.java
@@ -32,13 +32,13 @@ import static net.tylermurphy.hideAndSeek.configuration.Localization.message;
public class SetExitLocation implements ICommand {
public void execute(CommandSender sender, String[] args) {
- if(Game.status != Status.STANDBY) {
+ if (Game.status != Status.STANDBY) {
sender.sendMessage(errorPrefix + message("GAME_INPROGRESS"));
return;
}
Vector newExitPosition = new Vector();
Player player = (Player) sender;
- if(player.getLocation().getBlockX() == 0 || player.getLocation().getBlockZ() == 0 || player.getLocation().getBlockY() == 0){
+ if (player.getLocation().getBlockX() == 0 || player.getLocation().getBlockZ() == 0 || player.getLocation().getBlockY() == 0) {
sender.sendMessage(errorPrefix + message("NOT_AT_ZERO"));
return;
}
@@ -46,7 +46,7 @@ public class SetExitLocation implements ICommand {
newExitPosition.setY(player.getLocation().getBlockY());
newExitPosition.setZ(player.getLocation().getBlockZ());
World world = player.getLocation().getWorld();
- if(world == null){
+ if (world == null) {
throw new RuntimeException("Unable to get world: " + spawnWorld);
}
exitWorld = world.getName();