--- miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/GetposCommand.java 2013/12/06 08:55:50 2092 +++ miscJava/bukkit-minecraft-plugins/HoerupUtils/src/main/java/dk/thoerup/bukkit/hoeruputils/GetposCommand.java 2013/12/07 15:18:04 2093 @@ -1,6 +1,7 @@ package dk.thoerup.bukkit.hoeruputils; import org.bukkit.Location; +import org.bukkit.World; import org.bukkit.command.Command; import org.bukkit.command.CommandExecutor; import org.bukkit.command.CommandSender; @@ -17,8 +18,13 @@ Player p = (Player) sender; Location l = p.getLocation(); + + World world = l.getWorld(); + String worldMsg = "You are currently in world: " + world.getName(); + p.sendMessage( worldMsg ); + String message = String.format("Your current location is %d,%d,%d", (int)l.getX(), (int)l.getY(), (int)l.getZ() ); p.sendMessage(message);