diff --git a/Core/src/main/java/com/intellectualcrafters/plot/commands/Visit.java b/Core/src/main/java/com/intellectualcrafters/plot/commands/Visit.java index 77467c98b..36538f6b6 100644 --- a/Core/src/main/java/com/intellectualcrafters/plot/commands/Visit.java +++ b/Core/src/main/java/com/intellectualcrafters/plot/commands/Visit.java @@ -88,14 +88,23 @@ public class Visit extends Command { C.COMMAND_SYNTAX.send(player, getUsage()); return; } - - // we found nothing we now check for a combined command arg - if((args[0].contains(";") || args[0].contains(",")) && (unsorted == null || unsorted.isEmpty())) { - Plot plot = MainUtil.getPlotFromString(player, args[0], true); - if (plot != null) { - unsorted = Collections.singletonList(plot.getBasePlot(false)); - } - } + + if(unsorted == null || unsorted.isEmpty()) { + // we now check for a combined command arg + if(args[0].contains(";") || args[0].contains(",")) { + Plot plot = MainUtil.getPlotFromString(player, args[0], true); + if (plot != null) { + unsorted = Collections.singletonList(plot.getBasePlot(false)); + } + } else { // its not a combined command check for player search without result + UUID user = UUIDHandler.getUUIDFromString(args[0]); + if(user != null) { + // we know safe its a player (we can provide a specific message that we searched for player plots without result) + MainUtil.sendMessage(player, C.FOUND_NO_PLOTS_FOR_PLAYER, UUIDHandler.getName(user)); + return; + } + } + } break; case 0: @@ -224,7 +233,6 @@ public class Visit extends Command { } } catch (Exception ignored) { page = PAGE_OUT_OF_RANGE; - C.NOT_VALID_NUMBER.send(player, "(1, ∞)"); } return page; diff --git a/Core/src/main/java/com/intellectualcrafters/plot/config/C.java b/Core/src/main/java/com/intellectualcrafters/plot/config/C.java index 8658cfd10..e7d84ff5e 100644 --- a/Core/src/main/java/com/intellectualcrafters/plot/config/C.java +++ b/Core/src/main/java/com/intellectualcrafters/plot/config/C.java @@ -541,6 +541,7 @@ public enum C { NO_SUCH_PLOT("$2There is no such plot", "Invalid"), PLAYER_HAS_NOT_BEEN_ON("$2That player hasn't been in the plotworld", "Invalid"), FOUND_NO_PLOTS("$2Found no plots with your search query", "Invalid"), + FOUND_NO_PLOTS_FOR_PLAYER("$2No plots found for player: %s", "Invalid"), /* * Camera */