@@ -0,0 +1,1282 @@
+package us.crast.mondochest;%0A%0Aimport java.util.HashMap;%0Aimport java.util.Map;%0A%0Aimport org.bukkit.block.Block;%0Aimport org.bukkit.block.BlockFace;%0A%0Apublic class DirectionalStrings %7B%0A%09private static Map%3CString, BlockFace%3E dirs = new HashMap%3CString, BlockFace%3E();%0A%09%0A%09public static Block parseDirectional(Block context, String directioninfo) throws MondoMessage %7B%0A%09%09String%5B%5D directional = directioninfo.split(%22 %22);%0A%09%09if ((directional.length %25 2) != 0) %7B%0A%09%09%09throw new MondoMessage(%22Directional info specification is invalid%22);%0A%09%09%7D%0A%09%09for (int i = 0; i %3C directional.length; i+=2) %7B%0A%09%09%09BlockFace desired_face = dirs.get(directional%5Bi%5D.toUpperCase());%0A%09%09%09if (desired_face == null) %7B%0A%09%09%09%09throw new MondoMessage(String.format(%22Direction must be one of up/down/north/south/east/west, got '%7B0%7D'%22, directional%5Bi%5D));%0A%09%09%09%7D%0A%09%09%09int distance = Integer.parseInt(directional%5Bi+1%5D);%0A%09%09%09if (distance %3C 0) %7B%0A%09%09%09%09distance = -distance;%0A%09%09%09%09desired_face = desired_face.getOppositeFace();%0A%09%09%09%7D%0A%09%09%09context = context.getRelative(desired_face, distance);%0A%09%09%7D%0A%09%09return context;%0A%09%7D%0A%09%0A%09static %7B%0A%09%09dirs.put(%22UP%22, BlockFace.UP);%0A%09%09dirs.put(%22DOWN%22, BlockFace.DOWN);%0A%09%09dirs.put(%22EAST%22, BlockFace.EAST);%0A%09%09dirs.put(%22WEST%22, BlockFace.WEST);%0A%09%09dirs.put(%22NORTH%22, BlockFace.NORTH);%0A%09%09dirs.put(%22SOUTH%22, BlockFace.SOUTH);%0A%09%7D%0A%7D%0A

Add in support for parsing directional strings like 'up 7 east 12'