From e11469618dc5c407d8b40b3729f0ebb7ed747001 Mon Sep 17 00:00:00 2001 From: Paul Schulze Date: Sun, 10 Feb 2013 02:28:56 +0100 Subject: [PATCH] better output on border creation --- src/main/java/de/craftinc/borderprotection/Commands.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/main/java/de/craftinc/borderprotection/Commands.java b/src/main/java/de/craftinc/borderprotection/Commands.java index ba1773c..eb8035d 100644 --- a/src/main/java/de/craftinc/borderprotection/Commands.java +++ b/src/main/java/de/craftinc/borderprotection/Commands.java @@ -61,13 +61,17 @@ public class Commands implements CommandExecutor sender.sendMessage(Messages.noPermissionSet); return false; } + World world = ( (Player) sender ).getWorld(); + // set if ( args.length == 2 ) { try { borderManager.setBorder(( (Player) sender ).getWorld(), Double.parseDouble(args[1])); + Border border = Border.getBorders().get(world); sender.sendMessage(Messages.borderCreationSuccessful); + sender.sendMessage(Messages.borderInfo(world.getName(), border.toString())); } catch ( Exception e ) { @@ -80,6 +84,9 @@ public class Commands implements CommandExecutor try { borderManager.setBorder(( (Player) sender ).getWorld(), args[1], args[2]); + Border border = Border.getBorders().get(world); + sender.sendMessage(Messages.borderCreationSuccessful); + sender.sendMessage(Messages.borderInfo(world.getName(), border.toString())); } catch ( Exception e ) {