summaryrefslogtreewikicommitdiff
path: root/src/main/java/net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java')
-rw-r--r--src/main/java/net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java10
1 files changed, 4 insertions, 6 deletions
diff --git a/src/main/java/net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java b/src/main/java/net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java
index 31cad53..a8a1887 100644
--- a/src/main/java/net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java
+++ b/src/main/java/net/tylermurphy/hideAndSeek/command/SetLobbyLocation.java
@@ -26,12 +26,10 @@ public class SetLobbyLocation implements ICommand {
}
lobbyPosition = newLobbyPosition;
sender.sendMessage(messagePrefix + message("LOBBY_SPAWN"));
- Map<String, Object> temp = new HashMap<String,Object>();
- temp.put("x", lobbyPosition.getX());
- temp.put("y", lobbyPosition.getY());
- temp.put("z", lobbyPosition.getZ());
- temp.put("world", player.getLocation().getWorld().getName());
- addToSection("spawns.lobby",temp);
+ addToConfig("spawns.lobby.x", lobbyPosition.getX());
+ addToConfig("spawns.lobby.y", lobbyPosition.getY());
+ addToConfig("spawns.lobby.z", lobbyPosition.getZ());
+ addToConfig("spawns.lobby.world", player.getLocation().getWorld().getName());
saveConfig();
}