From 41052b27a08d4f6781196f070bbaa575afa4e47f Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Tue, 13 Aug 2019 21:57:49 +0200 Subject: [PATCH 01/15] I have some random ideas sometimes - Adjusting some RequiredTypes fitting their partners/default behavior - A plot doesn't need to be claimed to get the center - Adapting another gamemode acronym - Fix copyFile to adapt the latest changes - Removing HastebinUtility, we have our own paste service --- .../plotsquared/plot/PlotSquared.java | 2 +- .../plotsquared/plot/commands/Leave.java | 2 +- .../plotsquared/plot/commands/Middle.java | 5 +- .../plotsquared/plot/commands/Relight.java | 2 +- .../plotsquared/plot/commands/Remove.java | 2 +- .../plotsquared/plot/commands/SetHome.java | 2 +- .../plotsquared/plot/flag/GameModeFlag.java | 1 + .../plot/util/HastebinUtility.java | 70 ------------------- 8 files changed, 7 insertions(+), 79 deletions(-) delete mode 100644 Core/src/main/java/com/github/intellectualsites/plotsquared/plot/util/HastebinUtility.java diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java index 2f8fc8235..31c7710c2 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java @@ -251,12 +251,12 @@ import java.util.zip.ZipInputStream; copyFile("addplots.js", Settings.Paths.SCRIPTS); copyFile("addsigns.js", Settings.Paths.SCRIPTS); copyFile("automerge.js", Settings.Paths.SCRIPTS); + copyFile("fixborders.js", Settings.Paths.SCRIPTS); copyFile("furthest.js", Settings.Paths.SCRIPTS); copyFile("mycommand.js", Settings.Paths.SCRIPTS); copyFile("setbiomes.js", Settings.Paths.SCRIPTS); copyFile("start.js", Settings.Paths.SCRIPTS); copyFile("town.template", Settings.Paths.TEMPLATES); - copyFile("skyblock.template", Settings.Paths.TEMPLATES); copyFile("bridge.template", Settings.Paths.TEMPLATES); copyFile("de-DE.yml", Settings.Paths.TRANSLATIONS); copyFile("es-ES.yml", Settings.Paths.TRANSLATIONS); diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Leave.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Leave.java index cbc227bd3..b51993326 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Leave.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Leave.java @@ -16,7 +16,7 @@ import java.util.concurrent.CompletableFuture; @CommandDeclaration(command = "leave", description = "Removes self from being trusted or a member of the plot", permission = "plots.leave", category = CommandCategory.CLAIMING, - requiredType = RequiredType.NONE) public class Leave extends Command { + requiredType = RequiredType.PLAYER) public class Leave extends Command { public Leave() { super(MainCommand.getInstance(), true); } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Middle.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Middle.java index 8fbec1ecb..f3acaf5a0 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Middle.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Middle.java @@ -11,7 +11,7 @@ import com.github.intellectualsites.plotsquared.plot.object.PlotPlayer; */ @CommandDeclaration(command = "middle", aliases = {"center", "centre"}, description = "Teleports you to the center of the plot", usage = "/plot middle", - category = CommandCategory.TELEPORT, requiredType = RequiredType.NONE) public class Middle + category = CommandCategory.TELEPORT, requiredType = RequiredType.PLAYER) public class Middle extends SubCommand { @Override public boolean onCommand(PlotPlayer player, String[] arguments) { @@ -20,9 +20,6 @@ import com.github.intellectualsites.plotsquared.plot.object.PlotPlayer; if (plot == null) { return sendMessage(player, Captions.NOT_IN_PLOT); } - if (!plot.hasOwner()) { - return sendMessage(player, Captions.PLOT_UNOWNED); - } player.teleport(plot.getCenter()); return true; } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Relight.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Relight.java index 321f91d24..5af706df3 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Relight.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Relight.java @@ -10,7 +10,7 @@ import com.github.intellectualsites.plotsquared.plot.util.block.LocalBlockQueue; import java.util.concurrent.CompletableFuture; @CommandDeclaration(command = "relight", description = "Relight your plot", usage = "/plot relight", - category = CommandCategory.DEBUG) public class Relight extends Command { + category = CommandCategory.DEBUG, requiredType = RequiredType.PLAYER) public class Relight extends Command { public Relight() { super(MainCommand.getInstance(), true); } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Remove.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Remove.java index 875eb6e4c..af1c0024d 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Remove.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Remove.java @@ -19,7 +19,7 @@ import java.util.UUID; @CommandDeclaration(command = "remove", aliases = {"r", "untrust", "ut", "undeny", "unban", "ud"}, description = "Remove a player from a plot", usage = "/plot remove ", - category = CommandCategory.SETTINGS, requiredType = RequiredType.NONE, + category = CommandCategory.SETTINGS, requiredType = RequiredType.PLAYER, permission = "plots.remove") public class Remove extends SubCommand { public Remove() { diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SetHome.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SetHome.java index af0968a92..7a208ebd5 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SetHome.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SetHome.java @@ -10,7 +10,7 @@ import com.github.intellectualsites.plotsquared.plot.util.MainUtil; @CommandDeclaration(command = "sethome", permission = "plots.set.home", description = "Set the plot home to your current position", usage = "/plot sethome [none]", - aliases = {"sh", "seth"}, category = CommandCategory.SETTINGS, requiredType = RequiredType.NONE) + aliases = {"sh", "seth"}, category = CommandCategory.SETTINGS, requiredType = RequiredType.PLAYER) public class SetHome extends SetCommand { @Override public boolean set(PlotPlayer player, Plot plot, String value) { diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/flag/GameModeFlag.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/flag/GameModeFlag.java index 3467171f2..80225c2aa 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/flag/GameModeFlag.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/flag/GameModeFlag.java @@ -27,6 +27,7 @@ public class GameModeFlag extends Flag { case "2": return PlotGameMode.ADVENTURE; case "spectator": + case "sp": case "3": return PlotGameMode.SPECTATOR; default: diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/util/HastebinUtility.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/util/HastebinUtility.java deleted file mode 100644 index 3b0563a3d..000000000 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/util/HastebinUtility.java +++ /dev/null @@ -1,70 +0,0 @@ -package com.github.intellectualsites.plotsquared.plot.util; - -import java.io.BufferedReader; -import java.io.DataOutputStream; -import java.io.File; -import java.io.FileReader; -import java.io.IOException; -import java.io.InputStreamReader; -import java.net.HttpURLConnection; -import java.net.URL; -import java.util.ArrayList; -import java.util.List; -import java.util.regex.Matcher; -import java.util.regex.Pattern; - -public class HastebinUtility { - - public static final String BIN_URL = "https://hastebin.com/documents", USER_AGENT = - "Mozilla/5.0"; - public static final Pattern PATTERN = Pattern.compile("\\{\"key\":\"([\\S\\s]*)\"\\}"); - - public static String upload(final String string) throws IOException { - final URL url = new URL(BIN_URL); - final HttpURLConnection connection = (HttpURLConnection) url.openConnection(); - - connection.setRequestMethod("POST"); - connection.setRequestProperty("User-Agent", USER_AGENT); - connection.setDoOutput(true); - - try (DataOutputStream outputStream = new DataOutputStream(connection.getOutputStream())) { - outputStream.write(string.getBytes()); - outputStream.flush(); - } - - StringBuilder response; - try (BufferedReader in = new BufferedReader( - new InputStreamReader(connection.getInputStream()))) { - response = new StringBuilder(); - - String inputLine; - while ((inputLine = in.readLine()) != null) { - response.append(inputLine); - } - } - - Matcher matcher = PATTERN.matcher(response.toString()); - if (matcher.matches()) { - return "https://hastebin.com/" + matcher.group(1); - } else { - throw new RuntimeException("Couldn't read response!"); - } - } - - public static String upload(final File file) throws IOException { - List lines = new ArrayList<>(); - try (BufferedReader reader = new BufferedReader(new FileReader(file))) { - String line; - int i = 0; - while ((line = reader.readLine()) != null) { - lines.add(line); - } - } - final StringBuilder content = new StringBuilder(); - for (int i = Math.max(0, lines.size() - 1000); i < lines.size(); i++) { - content.append(lines.get(i)).append("\n"); - } - return upload(content.toString()); - } - -} From fbaef135537241efcd6be3452306e0037da96c7b Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Thu, 15 Aug 2019 15:39:37 +0200 Subject: [PATCH 02/15] Unify player string <> args are used in a lot of commands, PlayerName is used in only 3 commands and I don'T want to remove methods if not really necessary, so let's just change it here. --- .../github/intellectualsites/plotsquared/commands/Argument.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/commands/Argument.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/commands/Argument.java index dd5221a3a..7ae1985ce 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/commands/Argument.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/commands/Argument.java @@ -33,7 +33,7 @@ public abstract class Argument { } }; public static final Argument PlayerName = - new Argument("PlayerName", "Dinnerbone") { + new Argument("PlayerName", "") { @Override public String parse(String in) { return in.length() <= 16 ? in : null; } From b3e53e34b6a6dd4693b49d16d39b3108ad65bba6 Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Thu, 15 Aug 2019 16:20:30 +0200 Subject: [PATCH 03/15] Simplify help string --- .../plotsquared/plot/commands/WE_Anywhere.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/WE_Anywhere.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/WE_Anywhere.java index bd18e3886..3a4e1d71c 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/WE_Anywhere.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/WE_Anywhere.java @@ -4,7 +4,7 @@ import com.github.intellectualsites.plotsquared.commands.CommandDeclaration; import com.github.intellectualsites.plotsquared.plot.object.PlotPlayer; @CommandDeclaration(command = "weanywhere", permission = "plots.worldedit.bypass", - description = "Force bypass of WorldEdit", aliases = {"wea"}, usage = "/plot weanywhere", + description = "Force bypass of WorldEdit restrictions", aliases = {"wea"}, usage = "/plot weanywhere", requiredType = RequiredType.NONE, category = CommandCategory.ADMINISTRATION) @Deprecated public class WE_Anywhere extends SubCommand { From 8653b9b0a2773ca3b44bdd81d25d3325a0368bdd Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Thu, 15 Aug 2019 16:37:57 +0200 Subject: [PATCH 04/15] Update unfitting messages --- .../github/intellectualsites/plotsquared/plot/commands/Add.java | 2 +- .../intellectualsites/plotsquared/plot/commands/Deny.java | 2 +- .../intellectualsites/plotsquared/plot/commands/Trust.java | 2 +- .../intellectualsites/plotsquared/plot/config/Captions.java | 1 + 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Add.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Add.java index f6dba37a4..d92dd4ea3 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Add.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Add.java @@ -49,7 +49,7 @@ import java.util.concurrent.CompletableFuture; continue; } if (plot.isOwner(uuid)) { - MainUtil.sendMessage(player, Captions.ALREADY_OWNER, MainUtil.getName(uuid)); + MainUtil.sendMessage(player, Captions.ALREADY_ADDED, MainUtil.getName(uuid)); iterator.remove(); continue; } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Deny.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Deny.java index 7bb0ab34a..6d5dc99c7 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Deny.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Deny.java @@ -56,7 +56,7 @@ import java.util.UUID; continue; } if (plot.isOwner(uuid)) { - MainUtil.sendMessage(player, Captions.ALREADY_OWNER, MainUtil.getName(uuid)); + MainUtil.sendMessage(player, Captions.CANT_REMOVE_OWNER, MainUtil.getName(uuid)); return false; } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Trust.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Trust.java index 630e636d6..4531d2737 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Trust.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Trust.java @@ -52,7 +52,7 @@ import java.util.concurrent.CompletableFuture; continue; } if (currentPlot.isOwner(uuid)) { - MainUtil.sendMessage(player, Captions.ALREADY_OWNER, MainUtil.getName(uuid)); + MainUtil.sendMessage(player, Captions.ALREADY_ADDED, MainUtil.getName(uuid)); iterator.remove(); continue; } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java index 5fd74a9ea..a20898f5a 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java @@ -647,6 +647,7 @@ public enum Captions { DENIED_NEED_ARGUMENT("$2Arguments are missing. $1/plot denied add $2or $1/plot denied remove ", "Deny"), WAS_NOT_DENIED("$2That player was not denied on this plot", "Deny"), YOU_GOT_DENIED("$4You are denied from the plot you were previously on, and got teleported to spawn", "Deny"), + CANT_REMOVE_OWNER("$2You can't remove the plot owner", "Deny"), // YOU_GOT_KICKED("$4You got kicked!", "Kick"), // From 31c81fc9fe8850839facad8adef63c3b7ccdd952 Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Thu, 15 Aug 2019 17:35:40 +0200 Subject: [PATCH 05/15] Update command aliases format --- .../intellectualsites/plotsquared/plot/commands/Help.java | 2 +- .../intellectualsites/plotsquared/plot/commands/Kick.java | 2 +- .../intellectualsites/plotsquared/plot/commands/Load.java | 2 +- .../intellectualsites/plotsquared/plot/commands/Move.java | 2 +- .../intellectualsites/plotsquared/plot/commands/Visit.java | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Help.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Help.java index 47d9ea89b..7949df513 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Help.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Help.java @@ -14,7 +14,7 @@ import com.github.intellectualsites.plotsquared.plot.util.helpmenu.HelpMenu; import java.util.concurrent.CompletableFuture; -@CommandDeclaration(command = "help", description = "Get this help menu", aliases = {"he", "?"}, +@CommandDeclaration(command = "help", description = "Get this help menu", aliases = "?", category = CommandCategory.INFO, usage = "help [category|#]", permission = "plots.use") public class Help extends Command { public Help(Command parent) { diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Kick.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Kick.java index 2ffb6aa6a..eb36f8e67 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Kick.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Kick.java @@ -17,7 +17,7 @@ import java.util.HashSet; import java.util.Set; import java.util.UUID; -@CommandDeclaration(command = "kick", aliases = {"k"}, description = "Kick a player from your plot", +@CommandDeclaration(command = "kick", aliases = "k", description = "Kick a player from your plot", permission = "plots.kick", usage = "/plot kick ", category = CommandCategory.TELEPORT, requiredType = RequiredType.PLAYER) public class Kick extends SubCommand { diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Load.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Load.java index d18332798..4b0305969 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Load.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Load.java @@ -19,7 +19,7 @@ import java.net.MalformedURLException; import java.net.URL; import java.util.List; -@CommandDeclaration(command = "load", aliases = {"restore"}, category = CommandCategory.SCHEMATIC, +@CommandDeclaration(command = "load", aliases = "restore", category = CommandCategory.SCHEMATIC, requiredType = RequiredType.NONE, description = "Load your plot", permission = "plots.load", usage = "/plot load") public class Load extends SubCommand { diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Move.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Move.java index 0e6d78247..fb8464aea 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Move.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Move.java @@ -11,7 +11,7 @@ import com.github.intellectualsites.plotsquared.plot.util.MainUtil; import com.github.intellectualsites.plotsquared.plot.util.Permissions; @CommandDeclaration(usage = "/plot move ", command = "move", description = "Move a plot", - aliases = {"debugmove"}, permission = "plots.move", category = CommandCategory.CLAIMING, + permission = "plots.move", category = CommandCategory.CLAIMING, requiredType = RequiredType.PLAYER) public class Move extends SubCommand { @Override public boolean onCommand(final PlotPlayer player, String[] args) { diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Visit.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Visit.java index c9e7ed8e8..ea5647b66 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Visit.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Visit.java @@ -16,7 +16,7 @@ import java.util.concurrent.CompletableFuture; @CommandDeclaration(command = "visit", permission = "plots.visit", description = "Visit someones plot", usage = "/plot visit [|||] [#]", - aliases = {"v", "tp", "teleport", "goto", "home", "h"}, requiredType = RequiredType.PLAYER, + aliases = {"v", "tp", "teleport", "goto", "home", "h", "warp"}, requiredType = RequiredType.PLAYER, category = CommandCategory.TELEPORT) public class Visit extends Command { public Visit() { From 49b7c71fbb3fb638c04e5cad3b7ddffb8c16186f Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Fri, 16 Aug 2019 01:22:24 +0200 Subject: [PATCH 06/15] Adding some more translation strings --- .../plot/commands/CreateRoadSchematic.java | 3 +-- .../plotsquared/plot/commands/Download.java | 2 +- .../plot/commands/SchematicCmd.java | 25 ++++++++----------- .../plotsquared/plot/commands/Unlink.java | 2 +- .../plotsquared/plot/config/Captions.java | 15 +++++++++-- .../plot/listener/ProcessedWEExtent.java | 4 +-- 6 files changed, 29 insertions(+), 22 deletions(-) diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/CreateRoadSchematic.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/CreateRoadSchematic.java index 26962781c..2c901aa35 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/CreateRoadSchematic.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/CreateRoadSchematic.java @@ -25,8 +25,7 @@ import com.github.intellectualsites.plotsquared.plot.util.MainUtil; return sendMessage(player, Captions.NOT_IN_PLOT_WORLD); } HybridUtils.manager.setupRoadSchematic(plot); - MainUtil.sendMessage(player, - "$1Saved new road schematic. To test the road, fly to a few other plots and use /plot debugroadregen"); + MainUtil.sendMessage(player, Captions.SCHEMATIC_ROAD_CREATED); return true; } } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Download.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Download.java index 14521b2c6..776cff0f8 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Download.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Download.java @@ -76,7 +76,7 @@ import java.net.URL; Captions.NO_PERMISSION.send(player, Captions.PERMISSION_DOWNLOAD_WORLD); return false; } - MainUtil.sendMessage(player, "&cNote: The `.mca` files are 512x512"); + MainUtil.sendMessage(player, Captions.MCA_FILE_SIZE); plot.addRunning(); WorldUtil.IMP.saveWorld(world); WorldUtil.IMP.upload(plot, null, null, new RunnableVal() { diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SchematicCmd.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SchematicCmd.java index 24ccbe016..f654fa776 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SchematicCmd.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SchematicCmd.java @@ -62,7 +62,7 @@ public class SchematicCmd extends SubCommand { return false; } if (this.running) { - MainUtil.sendMessage(player, "&cTask is already running."); + MainUtil.sendMessage(player, Captions.TASK_IN_PROCESS); return false; } final String location = args[1]; @@ -148,8 +148,7 @@ public class SchematicCmd extends SubCommand { return false; } if (args.length != 2) { - MainUtil.sendMessage(player, - "&cNeed world argument. Use &7/plot sch exportall "); + MainUtil.sendMessage(player, Captions.SCHEMATIC_EXPORTALL_WORLD_ARGS); return false; } PlotArea area = PlotSquared.get().getPlotAreaByString(args[1]); @@ -160,19 +159,17 @@ public class SchematicCmd extends SubCommand { Collection plots = area.getPlots(); if (plots.isEmpty()) { MainUtil - .sendMessage(player, "&cInvalid world. Use &7/plot sch exportall "); + .sendMessage(player, Captions.SCHEMATIC_EXPORTALL_WORLD); return false; } boolean result = SchematicHandler.manager.exportAll(plots, null, null, - () -> MainUtil.sendMessage(player, "&aFinished mass export")); + () -> MainUtil.sendMessage(player, Captions.SCHEMATIC_EXPORTALL_FINISHED)); if (!result) { - MainUtil.sendMessage(player, "&cTask is already running."); + MainUtil.sendMessage(player, Captions.TASK_IN_PROCESS); return false; } else { - MainUtil.sendMessage(player, - "&3Plot&8->&3Schematic&8: &7Mass export has started. This may take a while."); - MainUtil.sendMessage(player, - "&3Plot&8->&3Schematic&8: &7Found &c" + plots.size() + "&7 plots..."); + MainUtil.sendMessage(player, Captions.SCHEMATIC_EXPORTALL_STARTED); + MainUtil.sendMessage(player, Captions.SCHEMATIC_EXPORTALL_COUNT, plots.size()); } break; } @@ -184,7 +181,7 @@ public class SchematicCmd extends SubCommand { return false; } if (this.running) { - MainUtil.sendMessage(player, "&cTask is already running."); + MainUtil.sendMessage(player, Captions.TASK_IN_PROCESS); return false; } Location location = player.getLocation(); @@ -203,14 +200,14 @@ public class SchematicCmd extends SubCommand { } ArrayList plots = Lists.newArrayList(plot); boolean result = SchematicHandler.manager.exportAll(plots, null, null, () -> { - MainUtil.sendMessage(player, "&aFinished export"); + MainUtil.sendMessage(player, Captions.SCHEMATIC_EXPORTALL_SINGLE_FINISHED); SchematicCmd.this.running = false; }); if (!result) { - MainUtil.sendMessage(player, "&cTask is already running."); + MainUtil.sendMessage(player, Captions.TASK_IN_PROCESS); return false; } else { - MainUtil.sendMessage(player, "&7Starting export..."); + MainUtil.sendMessage(player, Captions.SCHEMATIC_EXPORTALL_STARTED); } break; case "list": { diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Unlink.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Unlink.java index 9ce6bd5fb..7e84ef3aa 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Unlink.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Unlink.java @@ -41,7 +41,7 @@ public class Unlink extends SubCommand { } Runnable runnable = () -> { if (!plot.unlinkPlot(createRoad, createRoad)) { - MainUtil.sendMessage(player, "&cUnlink has been cancelled"); + MainUtil.sendMessage(player, Captions.UNMERGE_CANCELLED); return; } MainUtil.sendMessage(player, Captions.UNLINK_SUCCESS); diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java index a20898f5a..dca4f5b23 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java @@ -400,6 +400,15 @@ public enum Captions { "Schematics"), SCHEMATIC_PASTE_SUCCESS("$4The schematic pasted successfully", "Schematics"), SCHEMATIC_LIST("$4Saved Schematics: $1%s", "Schematics"), + SCHEMATIC_ROAD_CREATED("$1Saved new road schematic. To test the schematic, fly to a few other plots and run /plot debugroadregen", "Schematics"), + MCA_FILE_SIZE("$1Note: The `.mca` files are 512x512", "Schematics"), + SCHEMATIC_EXPORTALL_STARTED("$1Starting export...", "Schematics"), + SCHEMATIC_EXPORTALL_WORLD_ARGS("$1Need world argument. Use $3/plot sch exportall ", "Schematics"), + SCHEMATIC_EXPORTALL_WORLD("$1Invalid world. Use &3/plot sch exportall ", "Schematic"), + SCHEMATIC_EXPORTALL_MASS_STARTED("$1Schematic mass export has been started. This may take a while", "Schematics"), + SCHEMATIC_EXPORTALL_COUNT("$1Found $3%s $1plots...", "Schematics"), + SCHEMATIC_EXPORTALL_FINISHED("$1Finished mass export", "Schematics"), + SCHEMATIC_EXPORTALL_SINGLE_FINISHED("$1Finished export", "Schematics"), // // TITLE_ENTERED_PLOT("$1Plot: %world%;%x%;%z%", "Titles"), @@ -470,8 +479,9 @@ public enum Captions { NO_AVAILABLE_AUTOMERGE( "$2You do not own any adjacent plots in the specified direction or are not allowed to merge to the required size.", - "Merge"), UNLINK_REQUIRED("$2An unlink is required to do this.", "Merge"), - + "Merge"), + UNLINK_REQUIRED("$2An unlink is required to do this.", "Merge"), + UNMERGE_CANCELLED("$1Unlink has been cancelled", "Merge"), UNLINK_IMPOSSIBLE("$2You can only unlink a mega-plot", "Merge"), UNLINK_SUCCESS( "$2Successfully unlinked plots.", "Merge"), // @@ -505,6 +515,7 @@ public enum Captions { WAIT_FOR_TIMER( "$2A set block timer is bound to either the current plot or you. Please wait for it to finish", "Errors"), + TASK_IN_PROCESS("$1Task is already running.", "Error"), // DEBUG_REPORT_CREATED("$1Uploaded a full debug to: $1%url%", "Paste"), diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/listener/ProcessedWEExtent.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/listener/ProcessedWEExtent.java index 21014db70..7d2d824b4 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/listener/ProcessedWEExtent.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/listener/ProcessedWEExtent.java @@ -107,7 +107,7 @@ public class ProcessedWEExtent extends AbstractDelegateExtent { if (this.BScount > Settings.Chunk_Processor.MAX_TILES) { this.BSblocked = true; PlotSquared.debug( - Captions.PREFIX + "&cdetected unsafe WorldEdit: " + location.getX() + "," + Captions.PREFIX + "&cDetected unsafe WorldEdit: " + location.getX() + "," + location.getZ()); } if (WEManager @@ -162,7 +162,7 @@ public class ProcessedWEExtent extends AbstractDelegateExtent { if (this.Ecount > Settings.Chunk_Processor.MAX_ENTITIES) { this.Eblocked = true; PlotSquared.debug( - Captions.PREFIX + "&cdetected unsafe WorldEdit: " + location.getBlockX() + "," + Captions.PREFIX + "&cDetected unsafe WorldEdit: " + location.getBlockX() + "," + location.getBlockZ()); } if (WEManager.maskContains(this.mask, location.getBlockX(), location.getBlockY(), From b22919a278374922ad2d3fc02712efac033bcff6 Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Fri, 16 Aug 2019 01:47:22 +0200 Subject: [PATCH 07/15] Variable renames and fixes --- .../plotsquared/plot/PlotSquared.java | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java index 31c7710c2..174d88367 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java @@ -1601,7 +1601,7 @@ import java.util.zip.ZipInputStream; this.version = PlotVersion.tryParse(versionString, commitString, dateString); Settings.DATE = new Date(100 + version.year, version.month, version.day).toGMTString(); - Settings.BUILD = "https://ci.athion.net/job/PlotSquared/" + version.build; + Settings.BUILD = "https://ci.athion.net/job/PlotSquared-Breaking/" + version.build; Settings.COMMIT = "https://github.com/IntellectualSites/PlotSquared/commit/" + Integer .toHexString(version.hash); @@ -1777,15 +1777,15 @@ import java.util.zip.ZipInputStream; */ private void setupStyle() { if (this.version != null) { - this.style.set("version", this.version.toString()); + this.style.set("Version", this.version.toString()); } - Map o = new HashMap<>(4); - o.put("color.1", "6"); - o.put("color.2", "7"); - o.put("color.3", "8"); - o.put("color.4", "3"); + Map object = new HashMap<>(4); + object.put("color.1", "6"); + object.put("color.2", "7"); + object.put("color.3", "8"); + object.put("color.4", "3"); if (!this.style.contains("color")) { - for (Entry node : o.entrySet()) { + for (Entry node : object.entrySet()) { this.style.set(node.getKey(), node.getValue()); } } From 011baba140386bbaa4e47516c90c574626f48b2e Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Fri, 16 Aug 2019 02:05:51 +0200 Subject: [PATCH 08/15] Update PlotSquared.java --- .../github/intellectualsites/plotsquared/plot/PlotSquared.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java index 174d88367..f92c6a6fb 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/PlotSquared.java @@ -1601,7 +1601,7 @@ import java.util.zip.ZipInputStream; this.version = PlotVersion.tryParse(versionString, commitString, dateString); Settings.DATE = new Date(100 + version.year, version.month, version.day).toGMTString(); - Settings.BUILD = "https://ci.athion.net/job/PlotSquared-Breaking/" + version.build; + Settings.BUILD = "https://ci.athion.net/job/PlotSquared-Releases/" + version.build; Settings.COMMIT = "https://github.com/IntellectualSites/PlotSquared/commit/" + Integer .toHexString(version.hash); From be20b2404b3a1d8cf23eb9259109b4c44c2fdddb Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Sat, 17 Aug 2019 01:48:43 +0200 Subject: [PATCH 09/15] OCD - Typo Fixes - Small amendments (Spelling) - Reformatting --- .../plotsquared/plot/commands/Biome.java | 2 +- .../plotsquared/plot/commands/Merge.java | 2 +- .../plotsquared/plot/commands/Set.java | 2 +- .../plotsquared/plot/commands/Trust.java | 2 +- .../plotsquared/plot/config/Captions.java | 501 +++++++----------- 5 files changed, 206 insertions(+), 303 deletions(-) diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Biome.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Biome.java index 487c5d7c0..8b9ecb790 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Biome.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Biome.java @@ -17,7 +17,7 @@ import com.github.intellectualsites.plotsquared.plot.util.WorldUtil; int biome = WorldUtil.IMP.getBiomeFromString(value); if (biome == -1) { String biomes = StringMan - .join(WorldUtil.IMP.getBiomeList(), Captions.BLOCK_LIST_SEPARATER.getTranslated()); + .join(WorldUtil.IMP.getBiomeList(), Captions.BLOCK_LIST_SEPARATOR.getTranslated()); Captions.NEED_BIOME.send(player); MainUtil.sendMessage(player, Captions.SUBCOMMAND_SET_OPTIONS_HEADER.getTranslated() + biomes); diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Merge.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Merge.java index fcf5650b2..179761f94 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Merge.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Merge.java @@ -18,7 +18,7 @@ import com.github.intellectualsites.plotsquared.plot.util.UUIDHandler; import java.util.UUID; @CommandDeclaration(command = "merge", aliases = "m", - description = "Merge the plot you are standing on, with another plot", + description = "Merge the plot you are standing on with another plot", permission = "plots.merge", usage = "/plot merge [removeroads]", category = CommandCategory.SETTINGS, requiredType = RequiredType.NONE, confirmation = true) public class Merge extends SubCommand { diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Set.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Set.java index 982e03ae1..1f2d1c2a0 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Set.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Set.java @@ -128,7 +128,7 @@ import java.util.stream.IntStream; } MainUtil .sendMessage(player, Captions.SUBCOMMAND_SET_OPTIONS_HEADER.getTranslated() + StringMan - .join(newValues, Captions.BLOCK_LIST_SEPARATER.formatted())); + .join(newValues, Captions.BLOCK_LIST_SEPARATOR.formatted())); return false; } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Trust.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Trust.java index 4531d2737..c0cd3309e 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Trust.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Trust.java @@ -19,7 +19,7 @@ import java.util.concurrent.CompletableFuture; @CommandDeclaration(command = "trust", aliases = {"t"}, requiredType = RequiredType.PLAYER, usage = "/plot trust ", - description = "Allow a user to build in a plot while you are offline", + description = "Allow a user to build in a plot and use WorldEdit while you are offline", category = CommandCategory.SETTINGS) public class Trust extends Command { public Trust() { diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java index dca4f5b23..27f3fdeac 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java @@ -57,8 +57,8 @@ public enum Captions { PERMISSION_ADMIN_ENTRY_DENIED("plots.admin.entry.denied", "static.permissions"), PERMISSION_ADMIN_ENTRY_FORCEFIELD("plots.admin.entry.forcefield", "static.permissions"), PERMISSION_COMMANDS_CHAT("plots.admin.command.chat", "static.permissions"), - PERMISSION_MERGE_OTHER("plots.merge.other", "static.permissions"), PERMISSION_MERGE_KEEP_ROAD( - "plots.merge.keeproad", "static.permissions"), + PERMISSION_MERGE_OTHER("plots.merge.other", "static.permissions"), + PERMISSION_MERGE_KEEP_ROAD("plots.merge.keeproad", "static.permissions"), PERMISSION_ADMIN_DESTROY_UNOWNED("plots.admin.destroy.unowned", "static.permissions"), PERMISSION_ADMIN_DESTROY_GROUNDLEVEL("plots.admin.destroy.groundlevel", "static.permissions"), PERMISSION_ADMIN_DESTROY_OTHER("plots.admin.destroy.other", "static.permissions"), @@ -68,8 +68,8 @@ public enum Captions { PERMISSION_ADMIN_BUILD_OTHER("plots.admin.build.other", "static.permissions"), PERMISSION_ADMIN_INTERACT_ROAD("plots.admin.interact.road", "static.permissions"), PERMISSION_ADMIN_INTERACT_UNOWNED("plots.admin.interact.unowned", "static.permissions"), - PERMISSION_ADMIN_INTERACT_OTHER("plots.admin.interact.other", "static.permissions"), PERMISSION_ADMIN_BUILD_HEIGHT_LIMIT( - "plots.admin.build.heightlimit", "static.permissions"), + PERMISSION_ADMIN_INTERACT_OTHER("plots.admin.interact.other", "static.permissions"), + PERMISSION_ADMIN_BUILD_HEIGHT_LIMIT("plots.admin.build.heightlimit", "static.permissions"), PERMISSION_ADMIN_UPDATE("plots.admin.command.update", "static.permissions"), PERMISSION_ADMIN_COMMAND_RATE("plots.admin.command.rate", "static.permissions"), PERMISSION_ADMIN_COMMAND_TRUST("plots.admin.command.trust", "static.permissions"), @@ -122,8 +122,8 @@ public enum Captions { PERMISSION_FLAG_ADD("plots.flag.add", "static.permissions"), PERMISSION_FLAG_LIST("plots.flag.list", "static.permissions"), PERMISSION_ADMIN_COMMAND_KICK("plots.admin.command.kick", "static.permissions"), - PERMISSION_GRANT("plots.grant.%s0", "static.permissions"), PERMISSION_LIST_FOR_SALE( - "plots.list.forsale", "static.permissions"), + PERMISSION_GRANT("plots.grant.%s0", "static.permissions"), + PERMISSION_LIST_FOR_SALE("plots.list.forsale", "static.permissions"), PERMISSION_LIST_MINE("plots.list.mine", "static.permissions"), PERMISSION_LIST_SHARED("plots.list.shared", "static.permissions"), PERMISSION_LIST_WORLD("plots.list.world", "static.permissions"), @@ -138,8 +138,8 @@ public enum Captions { PERMISSION_LIST_FUZZY("plots.list.fuzzy", "static.permissions"), PERMISSION_LIST_AREA("plots.list.area", "static.permissions"), PERMISSION_ADMIN_COMMAND_LOAD("plots.admin.command.load", "static.permissions"), - PERMISSION_ADMIN_COMMAND_MERGE("plots.admin.command.merge", "static.permissions"), PERMISSION_ADMIN_COMMAND_SET_OWNER( - "plots.admin.command.setowner", "static.permissions"), + PERMISSION_ADMIN_COMMAND_MERGE("plots.admin.command.merge", "static.permissions"), + PERMISSION_ADMIN_COMMAND_SET_OWNER("plots.admin.command.setowner", "static.permissions"), PERMISSION_COMMENT("plots.comment", "static.permissions"), PERMISSION_ADMIN_COMMAND_REMOVE("plots.admin.command.remove", "static.permissions"), PERMISSION_ADMIN_COMMAND_SAVE("plots.admin.command.save", "static.permissions"), @@ -164,20 +164,19 @@ public enum Captions { CONSOLE_JAVA_OUTDATED( "&cYour version of java is outdated. It is highly recommended that you update to Java 8 as it increases performance " + "and security. %s0 will require Java 8 in a future update.", - "static.console"), CONSOLE_PLEASE_ENABLE_METRICS( + "static.console"), + CONSOLE_PLEASE_ENABLE_METRICS( "&dPlease enable metrics for %s0. Using metrics improves plugin stability, performance, and features. " + "Bug fixes and new features are influenced on metrics.", "static.console"), // // EXPIRED_CONFIRM("$2Confirmation has expired, please run the command again!", "Confirm"), FAILED_CONFIRM("$2You have no pending actions to confirm!", "Confirm"), - REQUIRES_CONFIRM( - "$2Are you sure you wish to execute: $1%s$2?&-$2This cannot be undone! If you are sure: $1/plot confirm", - "Confirm"), + REQUIRES_CONFIRM("$2Are you sure you wish to execute: $1%s$2?&-$2This cannot be undone! If you are sure: $1/plot confirm", "Confirm"), // // - MOVE_SUCCESS("$4Successfully moved plot.", "Move"), COPY_SUCCESS("$4Successfully copied plot.", - "Move"), + MOVE_SUCCESS("$4Successfully moved plot.", "Move"), + COPY_SUCCESS("$4Successfully copied plot.", "Move"), REQUIRES_UNOWNED("$2The location specified is already occupied.", "Move"), // // @@ -186,8 +185,7 @@ public enum Captions { // // GENERATING_LINK("$1Processing plot...", "Web"), - GENERATING_LINK_FAILED( - "$2Failed to generate download link!", "Web"), + GENERATING_LINK_FAILED("$2Failed to generate download link!", "Web"), SAVE_FAILED("$2Failed to save", "Web"), LOAD_NULL("$2Please use $4/plot load $2to get a list of schematics", "Web"), LOAD_FAILED("$2Failed to load schematic", "Web"), @@ -200,212 +198,163 @@ public enum Captions { // CLUSTER_AVAILABLE_ARGS( "$1The following sub commands are available: $4list$2, $4create$2, $4delete$2, $4resize$2, $4invite$2, $4kick$2, $4leave$2, " - + "$4members$2, $4info$2, $4tp$2, $4sethome", "Cluster"), CLUSTER_LIST_HEADING( - "$2There are $1%s$2 clusters in this world", "Cluster"), CLUSTER_LIST_ELEMENT("$2 - $1%s&-", - "Cluster"), CLUSTER_INTERSECTION( - "$2The proposed area overlaps with: %s0", "Cluster"), CLUSTER_OUTSIDE( - "$2The proposed area is outside the plot area: %s0", "Cluster"), CLUSTER_ADDED( - "$4Successfully created the cluster.", "Cluster"), CLUSTER_DELETED( - "$4Successfully deleted the cluster.", "Cluster"), CLUSTER_RESIZED( - "$4Successfully resized the cluster.", "Cluster"), CLUSTER_ADDED_USER( - "$4Successfully added user to the cluster.", "Cluster"), CANNOT_KICK_PLAYER( - "$2You cannot kick that player", "Cluster"), CLUSTER_INVITED( - "$1You have been invited to the following cluster: $2%s", "Cluster"), CLUSTER_REMOVED( - "$1You have been removed from cluster: $2%s", "Cluster"), CLUSTER_KICKED_USER( - "$4Successfully kicked the user", "Cluster"), INVALID_CLUSTER( - "$1Invalid cluster name: $2%s", "Cluster"), CLUSTER_NOT_ADDED( - "$2That player was not added to the plot cluster", "Cluster"), CLUSTER_CANNOT_LEAVE( - "$1You must delete or transfer ownership before leaving", - "Cluster"), CLUSTER_ADDED_HELPER("$4Successfully added a helper to the cluster", - "Cluster"), CLUSTER_REMOVED_HELPER("$4Successfully removed a helper from the cluster", - "Cluster"), CLUSTER_REGENERATED("$4Successfully started cluster regeneration", - "Cluster"), CLUSTER_TELEPORTING("$4Teleporting...", "Cluster"), - CLUSTER_INFO( - "$1Current cluster: $2%id%&-$1Name: $2%name%&-$1Owner: $2%owner%&-$1Size: $2%size%&-$1Rights: $2%rights%", - "Cluster"), + + "$4members$2, $4info$2, $4tp$2, $4sethome", "Cluster"), + CLUSTER_LIST_HEADING("$2There are $1%s$2 clusters in this world", "Cluster"), + CLUSTER_LIST_ELEMENT("$2 - $1%s&-", "Cluster"), + CLUSTER_INTERSECTION("$2The proposed area overlaps with: %s0", "Cluster"), + CLUSTER_OUTSIDE("$2The proposed area is outside the plot area: %s0", "Cluster"), + CLUSTER_ADDED("$4Successfully created the cluster.", "Cluster"), + CLUSTER_DELETED("$4Successfully deleted the cluster.", "Cluster"), + CLUSTER_RESIZED("$4Successfully resized the cluster.", "Cluster"), + CLUSTER_ADDED_USER("$4Successfully added user to the cluster.", "Cluster"), + CANNOT_KICK_PLAYER("$2You cannot kick that player", "Cluster"), + CLUSTER_INVITED("$1You have been invited to the following cluster: $2%s", "Cluster"), + CLUSTER_REMOVED("$1You have been removed from cluster: $2%s", "Cluster"), + CLUSTER_KICKED_USER("$4Successfully kicked the user", "Cluster"), + INVALID_CLUSTER("$1Invalid cluster name: $2%s", "Cluster"), + CLUSTER_NOT_ADDED("$2That player was not added to the plot cluster", "Cluster"), + CLUSTER_CANNOT_LEAVE("$1You must delete or transfer ownership before leaving", "Cluster"), + CLUSTER_ADDED_HELPER("$4Successfully added a helper to the cluster", "Cluster"), + CLUSTER_REMOVED_HELPER("$4Successfully removed a helper from the cluster", "Cluster"), + CLUSTER_REGENERATED("$4Successfully started cluster regeneration", "Cluster"), + CLUSTER_TELEPORTING("$4Teleporting...", "Cluster"), + CLUSTER_INFO("$1Current cluster: $2%id%&-$1Name: $2%name%&-$1Owner: $2%owner%&-$1Size: $2%size%&-$1Rights: $2%rights%", "Cluster"), // // BORDER("$2You are outside the current map border", "Border"), // - // - UNCLAIM_SUCCESS("$4You successfully unclaimed the plot.", "Unclaim"), UNCLAIM_FAILED( - "$2Could not unclaim the plot", "Unclaim"), + // + UNCLAIM_SUCCESS("$4You successfully unclaimed the plot.", "Unclaim"), + UNCLAIM_FAILED("$2Could not unclaim the plot", "Unclaim"), // // - WORLDEDIT_DELAYED("$2Please wait while we process your WorldEdit action...", - "WorldEdit Masks"), WORLDEDIT_RUN("$2Apologies for the delay. Now executing: %s", - "WorldEdit Masks"), - REQUIRE_SELECTION_IN_MASK( - "$2%s of your selection is not within your plot mask. You can only make edits within your plot.", - "WorldEdit Masks"), WORLDEDIT_VOLUME( - "$2You cannot select a volume of %current%. The maximum volume you can modify is %max%.", - "WorldEdit Masks"), - - WORLDEDIT_ITERATIONS( - "$2You cannot iterate %current% times. The maximum number of iterations allowed is %max%.", - "WorldEdit Masks"), WORLDEDIT_UNSAFE("$2Access to that command has been blocked", - "WorldEdit Masks"), - - WORLDEDIT_BYPASS("$2&oTo bypass your restrictions use $4/plot wea", - "WorldEdit Masks"), WORLDEDIT_BYPASSED("$2Currently bypassing WorldEdit restriction.", - "WorldEdit Masks"), - - WORLDEDIT_UNMASKED("$1Your WorldEdit is now unrestricted.", - "WorldEdit Masks"), WORLDEDIT_RESTRICTED("$1Your WorldEdit is now restricted.", - "WorldEdit Masks"), - - GAMEMODE_WAS_BYPASSED("$1You bypassed the GameMode ($2{gamemode}$1) $1set for $2{plot}", - "GameMode"), HEIGHT_LIMIT("$1This plot area has a height limit of $2{limit}", - "Height Limit"), + WORLDEDIT_DELAYED("$2Please wait while we process your WorldEdit action...", "WorldEdit Masks"), + WORLDEDIT_RUN("$2Apologies for the delay. Now executing: %s", "WorldEdit Masks"), + REQUIRE_SELECTION_IN_MASK("$2%s of your selection is not within your plot mask. You can only make edits within your plot.", "WorldEdit Masks"), + WORLDEDIT_VOLUME("$2You cannot select a volume of %current%. The maximum volume you can modify is %max%.", "WorldEdit Masks"), + WORLDEDIT_ITERATIONS("$2You cannot iterate %current% times. The maximum number of iterations allowed is %max%.", "WorldEdit Masks"), + WORLDEDIT_UNSAFE("$2Access to that command has been blocked","WorldEdit Masks"), + WORLDEDIT_BYPASS("$2&oTo bypass your restrictions use $4/plot wea", "WorldEdit Masks"), + WORLDEDIT_BYPASSED("$2Currently bypassing WorldEdit restriction.", "WorldEdit Masks"), + WORLDEDIT_UNMASKED("$1Your WorldEdit is now unrestricted.", "WorldEdit Masks"), + WORLDEDIT_RESTRICTED("$1Your WorldEdit is now restricted.", "WorldEdit Masks"), + // + // + GAMEMODE_WAS_BYPASSED("$1You bypassed the gamemode ($2{gamemode}$1) $1set for $2{plot}", "GameMode"), + // + // + HEIGHT_LIMIT("$1This plot area has a height limit of $2{limit}", "Height Limit"), // // NOTIFY_ENTER("$2%player $2entered your plot ($1%plot$2)", "Records"), NOTIFY_LEAVE("$2%player $2left your plot ($1%plot$2)", "Records"), // // - SWAP_OVERLAP("$2The proposed areas are not allowed to overlap", "Swap"), SWAP_DIMENSIONS( - "$2The proposed areas must have comparable dimensions", "Swap"), - - SWAP_SYNTAX("$2/plot swap ", "Swap"), SWAP_SUCCESS("$4Successfully swapped plots", "Swap"), - + SWAP_OVERLAP("$2The proposed areas are not allowed to overlap", "Swap"), + SWAP_DIMENSIONS("$2The proposed areas must have comparable dimensions", "Swap"), + SWAP_SYNTAX("$2/plot swap ", "Swap"), + SWAP_SUCCESS("$4Successfully swapped plots", "Swap"), STARTED_SWAP("$2Started plot swap task. You will be notified when it finishes", "Swap"), // - // - INBOX_NOTIFICATION("%s unread messages. Use /plot inbox", "Comment"), NOT_VALID_INBOX_INDEX( - "$2No comment at index %s", "Comment"), - - INBOX_ITEM("$2 - $4%s", "Comment"), COMMENT_SYNTAX("$2Use /plot comment [X;Z] <%s> ", - "Comment"), - - INVALID_INBOX("$2That is not a valid inbox.&-$1Accepted values: %s", "Comment"), NO_PERM_INBOX( - "$2You do not have permission for that inbox", "Comment"), - - NO_PERM_INBOX_MODIFY("$2You do not have permission to modify that inbox", - "Comment"), NO_PLOT_INBOX("$2You must stand in or supply a plot argument", "Comment"), - - COMMENT_REMOVED("$4Successfully deleted comment/s:n$2 - '$3%s$2'", "Comment"), COMMENT_ADDED( - "$4A comment has been left", "Comment"), - - COMMENT_HEADER("$2&m---------&r $1Comments $2&m---------&r", "Comment"), INBOX_EMPTY( - "$2No comments", "Comment"), + // + INBOX_NOTIFICATION("%s unread messages. Use /plot inbox", "Comment"), + NOT_VALID_INBOX_INDEX("$2No comment at index %s", "Comment"), + INBOX_ITEM("$2 - $4%s", "Comment"), + COMMENT_SYNTAX("$2Use /plot comment [X;Z] <%s> ", "Comment"), + INVALID_INBOX("$2That is not a valid inbox.&-$1Accepted values: %s", "Comment"), + NO_PERM_INBOX("$2You do not have permission for that inbox", "Comment"), + NO_PERM_INBOX_MODIFY("$2You do not have permission to modify that inbox","Comment"), + NO_PLOT_INBOX("$2You must stand in or supply a plot argument", "Comment"), + COMMENT_REMOVED("$4Successfully deleted comment/s:n$2 - '$3%s$2'", "Comment"), + COMMENT_ADDED("$4A comment has been left", "Comment"), + COMMENT_HEADER("$2&m---------&r $1Comments $2&m---------&r", "Comment"), + INBOX_EMPTY("$2No comments", "Comment"), // // - NOT_CONSOLE("$2For safety reasons, this command can only be executed by console.", - "Console"), IS_CONSOLE("$2This command can only be executed by a player.", "Console"), + NOT_CONSOLE("$2For safety reasons, this command can only be executed by console.", "Console"), + IS_CONSOLE("$2This command can only be executed by a player.", "Console"), // // - INVENTORY_USAGE("&cUsage: &6{usage}", "Inventory"), INVENTORY_DESC("&cDescription: &6{desc}", - "Inventory"), - + INVENTORY_USAGE("&cUsage: &6{usage}", "Inventory"), INVENTORY_DESC("&cDescription: &6{desc}", "Inventory"), INVENTORY_CATEGORY("&cCategory: &6{category}", "Inventory"), // // - CLIPBOARD_SET( - "$2The current plot is now copied to your clipboard, use $1/plot paste$2 to paste it", - "Clipboard"), PASTED( - "$4The plot selection was successfully pasted. It has been cleared from your clipboard.", - "Clipboard"), + CLIPBOARD_SET("$2The current plot is now copied to your clipboard, use $1/plot paste$2 to paste it", "Clipboard"), + PASTED("$4The plot selection was successfully pasted. It has been cleared from your clipboard.", "Clipboard"), - PASTE_FAILED("$2Failed to paste the selection. Reason: $2%s", "Clipboard"), NO_CLIPBOARD( - "$2You don't have a selection in your clipboard", "Clipboard"), - - CLIPBOARD_INFO( - "$2Current Selection - Plot ID: $1%id$2, Width: $1%width$2, Total Blocks: $1%total$2", - "Clipboard"), + PASTE_FAILED("$2Failed to paste the selection. Reason: $2%s", "Clipboard"), + NO_CLIPBOARD("$2You don't have a selection in your clipboard", "Clipboard"), + CLIPBOARD_INFO("$2Current Selection - Plot ID: $1%id$2, Width: $1%width$2, Total Blocks: $1%total$2", "Clipboard"), // // - TOGGLE_ENABLED("$2Enabled setting: %s", "Toggle"), TOGGLE_DISABLED("$2Disabled setting: %s", - "Toggle"), - + TOGGLE_ENABLED("$2Enabled setting: %s", "Toggle"), TOGGLE_DISABLED("$2Disabled setting: %s", "Toggle"), + // + // COMMAND_BLOCKED("$2That command is not allowed in this plot", "Blocked Command"), // // - - DONE_ALREADY_DONE("$2This plot is already marked as done", "Done"), DONE_NOT_DONE( - "$2This plot is not marked as done.", "Done"), - - DONE_INSUFFICIENT_COMPLEXITY( - "$2This plot is too simple. Please add more detail before using this command.", - "Done"), DONE_SUCCESS("$1Successfully marked this plot as done.", "Done"), - + DONE_ALREADY_DONE("$2This plot is already marked as done", "Done"), + DONE_NOT_DONE("$2This plot is not marked as done.", "Done"), + DONE_INSUFFICIENT_COMPLEXITY("$2This plot is too simple. Please add more detail before using this command.", "Done"), + DONE_SUCCESS("$1Successfully marked this plot as done.", "Done"), DONE_REMOVED("$1You may now continue building in this plot.", "Done"), // // - RATINGS_PURGED("$2Purged ratings for this plot", "Ratings"), RATING_NOT_VALID( - "$2You need to specify a number between 1 and 10", "Ratings"), - - RATING_ALREADY_EXISTS("$2You have already rated plot $2%s", "Ratings"), RATING_APPLIED( - "$4You successfully rated plot $2%s", "Ratings"), - - RATING_DISLIKED("$4You successfully disliked plot $2%s", "Ratings"), RATING_LIKED( - "$4You successfully liked plot $2%s", "Ratings"), - - RATING_NOT_YOUR_OWN("$2You cannot rate your own plot", "Ratings"), RATING_NOT_DONE( - "$2You can only rate finished plots.", "Ratings"), - + RATINGS_PURGED("$2Purged ratings for this plot", "Ratings"), + RATING_NOT_VALID("$2You need to specify a number between 1 and 10", "Ratings"), + RATING_ALREADY_EXISTS("$2You have already rated plot $2%s", "Ratings"), + RATING_APPLIED("$4You successfully rated plot $2%s", "Ratings"), + RATING_DISLIKED("$4You successfully disliked plot $2%s", "Ratings"), + RATING_LIKED("$4You successfully liked plot $2%s", "Ratings"), + RATING_NOT_YOUR_OWN("$2You cannot rate your own plot", "Ratings"), + RATING_NOT_DONE("$2You can only rate finished plots.", "Ratings"), RATING_NOT_OWNED("$2You cannot rate a plot that is not claimed by anyone", "Ratings"), // // - RATE_THIS("$2Rate this plot!", "Tutorial"), COMMENT_THIS( - "$2Leave some feedback on this plot: %s", "Tutorial"), + RATE_THIS("$2Rate this plot!", "Tutorial"), + COMMENT_THIS("$2Leave some feedback on this plot: %s", "Tutorial"), // // - ECON_DISABLED("$2Economy is not enabled", "Economy"), CANNOT_AFFORD_PLOT( - "$2You cannot afford to buy this plot. It costs $1%s", "Economy"), - - NOT_FOR_SALE("$2This plot is not for sale", "Economy"), CANNOT_BUY_OWN( - "$2You cannot buy your own plot", "Economy"), - - PLOT_SOLD("$4Your plot; $1%s0$4, has been sold to $1%s1$4 for $1$%s2", - "Economy"), CANNOT_AFFORD_MERGE("$2You cannot afford to merge the plots. It costs $1%s", - "Economy"), - - ADDED_BALANCE("$1%s $2has been added to your balance", "Economy"), REMOVED_BALANCE( - "$1%s $2has been taken from your balance", "Economy"), - + ECON_DISABLED("$2Economy is not enabled", "Economy"), + CANNOT_AFFORD_PLOT("$2You cannot afford to buy this plot. It costs $1%s", "Economy"), + NOT_FOR_SALE("$2This plot is not for sale", "Economy"), + CANNOT_BUY_OWN("$2You cannot buy your own plot", "Economy"), + PLOT_SOLD("$4Your plot; $1%s0$4, has been sold to $1%s1$4 for $1$%s2", "Economy"), + CANNOT_AFFORD_MERGE("$2You cannot afford to merge the plots. It costs $1%s", "Economy"), + ADDED_BALANCE("$1%s $2has been added to your balance", "Economy"), + REMOVED_BALANCE("$1%s $2has been taken from your balance", "Economy"), REMOVED_GRANTED_PLOT("$2You used %s plot grant(s), you've got $1%s $2left", "Economy"), // // - SETUP_INIT("$1Usage: $2/plot setup ", "Setup"), SETUP_STEP( - "$3[$1Step %s0$3] $1%s1 $2- $1Expecting: $2%s2 $1Default: $2%s3", "Setup"), - - SETUP_INVALID_ARG( - "$2%s0 is not a valid argument for step %s1. To cancel setup use: $1/plot setup cancel", - "Setup"), SETUP_VALID_ARG("$2Value $1%s0 $2set to %s1", "Setup"), - + SETUP_INIT("$1Usage: $2/plot setup ", "Setup"), + SETUP_STEP("$3[$1Step %s0$3] $1%s1 $2- $1Expecting: $2%s2 $1Default: $2%s3", "Setup"), + SETUP_INVALID_ARG("$2%s0 is not a valid argument for step %s1. To cancel setup use: $1/plot setup cancel", "Setup"), + SETUP_VALID_ARG("$2Value $1%s0 $2set to %s1", "Setup"), SETUP_FINISHED( "$4You should have been teleported to the created world. Otherwise you will need to set the generator manually using the bukkit.yml or " - + "your chosen world management plugin.", "Setup"), SETUP_WORLD_TAKEN( - "$2%s is already a world", "Setup"), - + + "your chosen world management plugin.", "Setup"), + SETUP_WORLD_TAKEN("$2%s is already a world", "Setup"), SETUP_MISSING_WORLD( "$2You need to specify a world name ($1/plot setup &l$1 $2)&-$1Additional commands:&-$2 - $1/plot setup &-$2 -" + " $1/plot setup back&-$2 - $1/plot setup cancel", "Setup"), SETUP_MISSING_GENERATOR( "$2You need to specify a generator ($1/plot setup &l&r$2)&-$1Additional commands:&-$2 - $1/plot setup &-$2 - " + "$1/plot setup back&-$2 - $1/plot setup cancel", "Setup"), - SETUP_INVALID_GENERATOR("$2Invalid generator. Possible options: %s", "Setup"), // - // - - SCHEMATIC_TOO_LARGE("$2The plot is too large for this action!", - "Schematics"), SCHEMATIC_MISSING_ARG( - "$2You need to specify an argument. Possible values: $1test $2 , $1save$2 , $1paste $2, $1exportall$2, $1list", - "Schematics"), - - SCHEMATIC_INVALID("$2That is not a valid schematic. Reason: $2%s", - "Schematics"), SCHEMATIC_VALID("$2That is a valid schematic", "Schematics"), - - SCHEMATIC_PASTE_FAILED("$2Failed to paste the schematic", - "Schematics"), SCHEMATIC_PASTE_SUCCESS("$4The schematic pasted successfully", "Schematics"), - + // + SCHEMATIC_TOO_LARGE("$2The plot is too large for this action!", "Schematics"), + SCHEMATIC_MISSING_ARG("$2You need to specify an argument. Possible values: $1test $2 , $1save$2 , $1paste $2, $1exportall$2, $1list", "Schematics"), + SCHEMATIC_INVALID("$2That is not a valid schematic. Reason: $2%s", "Schematics"), + SCHEMATIC_VALID("$2That is a valid schematic", "Schematics"), + SCHEMATIC_PASTE_FAILED("$2Failed to paste the schematic", "Schematics"), + SCHEMATIC_PASTE_SUCCESS("$4The schematic pasted successfully", "Schematics"), SCHEMATIC_LIST("$4Saved Schematics: $1%s", "Schematics"), SCHEMATIC_ROAD_CREATED("$1Saved new road schematic. To test the schematic, fly to a few other plots and run /plot debugroadregen", "Schematics"), MCA_FILE_SIZE("$1Note: The `.mca` files are 512x512", "Schematics"), SCHEMATIC_EXPORTALL_STARTED("$1Starting export...", "Schematics"), - SCHEMATIC_EXPORTALL_WORLD_ARGS("$1Need world argument. Use $3/plot sch exportall ", "Schematics"), - SCHEMATIC_EXPORTALL_WORLD("$1Invalid world. Use &3/plot sch exportall ", "Schematic"), - SCHEMATIC_EXPORTALL_MASS_STARTED("$1Schematic mass export has been started. This may take a while", "Schematics"), + SCHEMATIC_EXPORTALL_WORLD_ARGS("$1Need world argument. Use $3/plot schem exportall ", "Schematics"), + SCHEMATIC_EXPORTALL_WORLD("$1Invalid world. Use &3/plot sch exportall ", "Schematics"), + SCHEMATIC_EXPORTALL_MASS_STARTED("$1Schematic mass export has been started. This may take a while", "Schematicss"), SCHEMATIC_EXPORTALL_COUNT("$1Found $3%s $1plots...", "Schematics"), SCHEMATIC_EXPORTALL_FINISHED("$1Finished mass export", "Schematics"), SCHEMATIC_EXPORTALL_SINGLE_FINISHED("$1Finished export", "Schematics"), @@ -425,75 +374,58 @@ public enum Captions { RELOADED_CONFIGS("$1Translations and world settings have been reloaded", "Reload"), RELOAD_FAILED("$2Failed to reload file configurations", "Reload"), // - // + // DESC_SET("$2Plot description set", "Desc"), DESC_UNSET("$2Plot description unset", "Desc"), MISSING_DESC("$2You need to specify a description", "Desc"), // // - - ALIAS_SET_TO("$2Plot alias set to $1%alias%", "Alias"), ALIAS_REMOVED("$2Plot alias removed", - "Alias"), - - MISSING_ALIAS("$2You need to specify an alias", "Alias"), ALIAS_TOO_LONG( - "$2The alias must be < 50 characters in length", "Alias"), - + ALIAS_SET_TO("$2Plot alias set to $1%alias%", "Alias"), + ALIAS_REMOVED("$2Plot alias removed", "Alias"), + MISSING_ALIAS("$2You need to specify an alias", "Alias"), + ALIAS_TOO_LONG("$2The alias must be < 50 characters in length", "Alias"), ALIAS_IS_TAKEN("$2That alias is already taken", "Alias"), // // - - MISSING_POSITION("$2You need to specify a position. Possible values: $1none", - "Position"), POSITION_SET("$1Home position set to your current location", "Position"), - - POSITION_UNSET("$1Home position reset to the default location", "Position"), HOME_ARGUMENT( - "$2Use /plot set home [none]", "Position"), - + MISSING_POSITION("$2You need to specify a position. Possible values: $1none", "Position"), + POSITION_SET("$1Home position set to your current location", "Position"), + POSITION_UNSET("$1Home position reset to the default location", "Position"), + HOME_ARGUMENT("$2Use /plot set home [none]", "Position"), INVALID_POSITION("$2That is not a valid position value", "Position"), // // - ENTITY_CAP("$2You are not allowed to spawn more mobs", "cap"), + ENTITY_CAP("$2You are not allowed to spawn more mobs", "Cap"), // // - NO_SCHEMATIC_PERMISSION("$2You don't have the permission required to use schematic $1%s", - "Permission"), + NO_SCHEMATIC_PERMISSION("$2You don't have the permission required to use schematic $1%s", "Permission"), NO_PERMISSION("$2You are lacking the permission node: $1%s", "Permission"), NO_PERMISSION_EVENT("$2You are lacking the permission node: $1%s", "Permission"), NO_PLOT_PERMS("$2You must be the plot owner to perform this action", "Permission"), CANT_CLAIM_MORE_PLOTS("$2You can't claim more plots.", "Permission"), CANT_CLAIM_MORE_CLUSTERS("$2You can't claim more clusters.", "Permission"), - - CANT_TRANSFER_MORE_PLOTS("$2You can't send more plots to that user", - "Permission"), CANT_CLAIM_MORE_PLOTS_NUM("$2You can't claim more than $1%s $2plots at once", - "Permission"), - + CANT_TRANSFER_MORE_PLOTS("$2You can't send more plots to that user", "Permission"), + CANT_CLAIM_MORE_PLOTS_NUM("$2You can't claim more than $1%s $2plots at once", "Permission"), // // - MERGE_NOT_VALID("$2This merge request is no longer valid.", "Merge"), MERGE_ACCEPTED( - "$2The merge request has been accepted", "Merge"), - - SUCCESS_MERGE("$2Plots have been merged!", "Merge"), MERGE_REQUESTED( - "$2Successfully sent a merge request", "Merge"), - - MERGE_REQUEST_CONFIRM("Merge request from %s", "Permission"), NO_PERM_MERGE( - "$2You are not the owner of the plot: $1%plot%", "Merge"), - - NO_AVAILABLE_AUTOMERGE( - "$2You do not own any adjacent plots in the specified direction or are not allowed to merge to the required size.", - "Merge"), + MERGE_NOT_VALID("$2This merge request is no longer valid.", "Merge"), + MERGE_ACCEPTED("$2The merge request has been accepted", "Merge"), + SUCCESS_MERGE("$2Plots have been merged!", "Merge"), + MERGE_REQUESTED("$2Successfully sent a merge request", "Merge"), + MERGE_REQUEST_CONFIRM("Merge request from %s", "Permission"), + NO_PERM_MERGE("$2You are not the owner of the plot: $1%plot%", "Merge"), + NO_AVAILABLE_AUTOMERGE("$2You do not own any adjacent plots in the specified direction or are not allowed to merge to the required size.", "Merge"), UNLINK_REQUIRED("$2An unlink is required to do this.", "Merge"), UNMERGE_CANCELLED("$1Unlink has been cancelled", "Merge"), - UNLINK_IMPOSSIBLE("$2You can only unlink a mega-plot", "Merge"), UNLINK_SUCCESS( - "$2Successfully unlinked plots.", "Merge"), + UNLINK_IMPOSSIBLE("$2You can only unlink a mega-plot", "Merge"), + UNLINK_SUCCESS("$2Successfully unlinked plots.", "Merge"), // // - NOT_VALID_SUBCOMMAND("$2That is not a valid subcommand", "CommandConfig"), DID_YOU_MEAN( - "$2Did you mean: $1%s", "CommandConfig"), - - NAME_LITTLE("$2%s0 name is too short, $1%s1$2<$1%s3", "CommandConfig"), NO_COMMANDS( - "$2I'm sorry, but you're not permitted to use any subcommands.", "CommandConfig"), - - SUBCOMMAND_SET_OPTIONS_HEADER("$2Possible Values: ", "CommandConfig"), COMMAND_SYNTAX( - "$1Usage: $2%s", "CommandConfig"), + NOT_VALID_SUBCOMMAND("$2That is not a valid subcommand", "CommandConfig"), + DID_YOU_MEAN("$2Did you mean: $1%s", "CommandConfig"), + NAME_LITTLE("$2%s0 name is too short, $1%s1$2<$1%s3", "CommandConfig"), + NO_COMMANDS("$2I'm sorry, but you're not permitted to use any subcommands.", "CommandConfig"), + SUBCOMMAND_SET_OPTIONS_HEADER("$2Possible Values: ", "CommandConfig"), + COMMAND_SYNTAX("$1Usage: $2%s", "CommandConfig"), // // INVALID_PLAYER_WAIT("$2Player not found: $1%s$2, fetching it. Try again soon.", "Errors"), @@ -505,75 +437,61 @@ public enum Captions { NO_FREE_PLOTS("$2There are no free plots available", "Errors"), NOT_IN_PLOT("$2You're not in a plot", "Errors"), NOT_LOADED("$2The plot could not be loaded", "Errors"), - NOT_IN_CLUSTER( - "$2You must be within a plot cluster to perform that action", "Errors"), + NOT_IN_CLUSTER("$2You must be within a plot cluster to perform that action", "Errors"), NOT_IN_PLOT_WORLD("$2You're not in a plot area", "Errors"), PLOTWORLD_INCOMPATIBLE("$2The two worlds must be compatible", "Errors"), NOT_VALID_WORLD("$2That is not a valid world (case sensitive)", "Errors"), NOT_VALID_PLOT_WORLD("$2That is not a valid plot area (case sensitive)", "Errors"), NO_PLOTS("$2You don't have any plots", "Errors"), - WAIT_FOR_TIMER( - "$2A set block timer is bound to either the current plot or you. Please wait for it to finish", - "Errors"), + WAIT_FOR_TIMER("$2A set block timer is bound to either the current plot or you. Please wait for it to finish", "Errors"), TASK_IN_PROCESS("$1Task is already running.", "Error"), // + // DEBUG_REPORT_CREATED("$1Uploaded a full debug to: $1%url%", "Paste"), - + // + // PURGE_SUCCESS("$4Successfully purged %s plots", "Purge"), - + // // TRIM_IN_PROGRESS("A world trim task is already in progress!", "Trim"), NOT_VALID_HYBRID_PLOT_WORLD("The hybrid plot manager is required to perform this action", "Trim"), // // - - BLOCK_LIST_SEPARATER("$1,$2 ", "Block List"), + BLOCK_LIST_SEPARATOR("$1,$2 ", "Block List"), // // - - NEED_BIOME("$2You need to specify a valid biome.", "Biome"), BIOME_SET_TO( - "$2Plot biome set to $2", "Biome"), + NEED_BIOME("$2You need to specify a valid biome.", "Biome"), + BIOME_SET_TO("$2Plot biome set to $2", "Biome"), // // - - TELEPORTED_TO_PLOT("$1You have been teleported", "Teleport"), TELEPORTED_TO_ROAD( - "$2You got teleported to the road", "Teleport"), - - TELEPORT_IN_SECONDS("$1Teleporting in %s seconds. Do not move...", "Teleport"), TELEPORT_FAILED( - "$2Teleportation cancelled due to movement or damage", "Teleport"), + TELEPORTED_TO_PLOT("$1You have been teleported", "Teleport"), + TELEPORTED_TO_ROAD("$2You got teleported to the road", "Teleport"), + TELEPORT_IN_SECONDS("$1Teleporting in %s seconds. Do not move...", "Teleport"), + TELEPORT_FAILED("$2Teleportation cancelled due to movement or damage", "Teleport"), // // - SET_BLOCK_ACTION_FINISHED("$1The last setblock action is now finished.", "Set Block"), // - // - - DEBUGALLOWUNSAFE_ON("$2Unsafe actions allowed", "unsafe"), DEBUGALLOWUNSAFE_OFF( - "$2Unsafe actions disabled", "unsafe"), + // + DEBUGALLOWUNSAFE_ON("$2Unsafe actions allowed", "unsafe"), + DEBUGALLOWUNSAFE_OFF("$2Unsafe actions disabled", "unsafe"), // // - - DEBUG_HEADER("$1Debug Information&-", "Debug"), DEBUG_SECTION("$2>> $1&l%val%", "Debug"), - + DEBUG_HEADER("$1Debug Information&-", "Debug"), + DEBUG_SECTION("$2>> $1&l%val%", "Debug"), DEBUG_LINE("$2>> $1%var%$2:$1 %val%&-", "Debug"), // // - - NOT_VALID_DATA("$2That's not a valid data id.", "Invalid"), NOT_VALID_BLOCK( - "$2That's not a valid block: %s", "Invalid"), - - NOT_ALLOWED_BLOCK("$2That block is not allowed: %s", "Invalid"), NOT_VALID_NUMBER( - "$2That's not a valid number within the range: %s", "Invalid"), - - NOT_VALID_PLOT_ID("$2That's not a valid plot id.", "Invalid"), PLOT_ID_FORM( - "$2The plot id must be in the form: $1X;Y $2e.g. $1-5;7", "Invalid"), - - NOT_YOUR_PLOT("$2That is not your plot.", "Invalid"), 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"), - + NOT_VALID_DATA("$2That's not a valid data id.", "Invalid"), + NOT_VALID_BLOCK("$2That's not a valid block: %s", "Invalid"), + NOT_ALLOWED_BLOCK("$2That block is not allowed: %s", "Invalid"), + NOT_VALID_NUMBER("$2That's not a valid number within the range: %s", "Invalid"), + NOT_VALID_PLOT_ID("$2That's not a valid plot id.", "Invalid"), + PLOT_ID_FORM("$2The plot id must be in the form: $1X;Y $2e.g. $1-5;7", "Invalid"), + NOT_YOUR_PLOT("$2That is not your plot.", "Invalid"), + 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"), // // @@ -588,43 +506,33 @@ public enum Captions { // // NONE("None", "Info"), NOW("Now", "Info"), - NEVER("Never", "Info"), UNKNOWN("Unknown", "Info"), - SERVER("Server", "Info"), - EVERYONE("Everyone", "Info"), - PLOT_UNOWNED( - "$2The current plot must have an owner to perform this action", "Info"), - - PLOT_INFO_UNCLAIMED("$2Plot $1%s$2 is not yet claimed", "Info"), PLOT_INFO_HEADER( - "$3&m---------&r $1INFO $3&m---------", false, "Info"), - + PLOT_UNOWNED("$2The current plot must have an owner to perform this action", "Info"), + PLOT_INFO_UNCLAIMED("$2Plot $1%s$2 is not yet claimed", "Info"), + PLOT_INFO_HEADER("$3&m---------&r $1INFO $3&m---------", false, "Info"), PLOT_INFO_HIDDEN("$2You cannot view the information about this plot", "Info"), - PLOT_INFO("$1ID: $2%id%$1&-" + "$1Alias: $2%alias%$1&-" + "$1Owner: $2%owner%$1&-" + "$1Biome: $2%biome%$1&-" + "$1Can Build: $2%build%$1&-" + "$1Rating: $2%rating%&-" + "$1Seen: $2%seen%&-" + "$1Trusted: $2%trusted%$1&-" + "$1Members: $2%members%$1&-" + "$1Denied: $2%denied%$1&-" + "$1Flags: $2%flags%", "Info"), - PLOT_INFO_FOOTER( - "$3&m---------&r $1INFO $3&m---------", false, "Info"), - + PLOT_INFO_FOOTER("$3&m---------&r $1INFO $3&m---------", false, "Info"), PLOT_INFO_TRUSTED("$1Trusted:$2 %trusted%", "Info"), PLOT_INFO_MEMBERS("$1Members:$2 %members%", "Info"), - - PLOT_INFO_DENIED("$1Denied:$2 %denied%", "Info"), PLOT_INFO_FLAGS("$1Flags:$2 %flags%", "Info"), - - PLOT_INFO_BIOME("$1Biome:$2 %biome%", "Info"), PLOT_INFO_RATING("$1Rating:$2 %rating%", "Info"), - + PLOT_INFO_DENIED("$1Denied:$2 %denied%", "Info"), + PLOT_INFO_FLAGS("$1Flags:$2 %flags%", "Info"), + PLOT_INFO_BIOME("$1Biome:$2 %biome%", "Info"), + PLOT_INFO_RATING("$1Rating:$2 %rating%", "Info"), PLOT_INFO_LIKES("$1Like Ratio:$2 %likes%%", "Info"), - - PLOT_INFO_OWNER("$1Owner:$2 %owner%", "Info"), PLOT_INFO_ID("$1ID:$2 %id%", "Info"), - - PLOT_INFO_ALIAS("$1Alias:$2 %alias%", "Info"), PLOT_INFO_SIZE("$1Size:$2 %size%", "Info"), - - PLOT_INFO_SEEN("$1Seen:$2 %seen%", "Info"), PLOT_USER_LIST(" $1%user%$2,", "Info"), - - PLOT_FLAG_LIST("$1%s0:%s1$2", "Info"), INFO_SYNTAX_CONSOLE("$2/plot info X;Y", "Info"), + PLOT_INFO_OWNER("$1Owner:$2 %owner%", "Info"), + PLOT_INFO_ID("$1ID:$2 %id%", "Info"), + PLOT_INFO_ALIAS("$1Alias:$2 %alias%", "Info"), + PLOT_INFO_SIZE("$1Size:$2 %size%", "Info"), + PLOT_INFO_SEEN("$1Seen:$2 %seen%", "Info"), + PLOT_USER_LIST(" $1%user%$2,", "Info"), + PLOT_FLAG_LIST("$1%s0:%s1$2", "Info"), + INFO_SYNTAX_CONSOLE("$2/plot info X;Y", "Info"), // // GENERATING_COMPONENT("$1Started generating component from your settings", "Working"), @@ -660,7 +568,9 @@ public enum Captions { YOU_GOT_DENIED("$4You are denied from the plot you were previously on, and got teleported to spawn", "Deny"), CANT_REMOVE_OWNER("$2You can't remove the plot owner", "Deny"), // + // YOU_GOT_KICKED("$4You got kicked!", "Kick"), + // // FLAG_KEY("$2Key: %s", "Flag"), FLAG_TYPE("$2Type: %s", "Flag"), @@ -684,15 +594,13 @@ public enum Captions { // REMOVED_PLAYERS("$2Removed %s players from this plot.", "Member"), ALREADY_OWNER("$2That user is already the plot owner: %s0", "Member"), - ALREADY_ADDED("$2That user is already added to that category: %s0", "Member"), MEMBER_ADDED("$4That user can now build while the plot owner is online", "Member"), - MEMBER_REMOVED("$1You successfully removed a user from the plot", "Member"), MEMBER_WAS_NOT_ADDED("$2That player was not added as a user on this plot", "Member"), PLOT_MAX_MEMBERS("$2You are not allowed to add any more players to this plot", "Member"), // - // + // SET_OWNER("$4You successfully set the plot owner", "Owner"), SET_OWNER_CANCELLED("$2The set owner action was cancelled", "Owner"), NOW_OWNER("$4You are now owner of plot %s", "Owner"), @@ -712,10 +620,8 @@ public enum Captions { HELP_DISPLAY_ALL_COMMANDS("Display all commands", "Help"), DIRECTION("$1Current direction: %dir%", "Help"), // - - BUCKET_ENTRIES_IGNORED( - "$2Total bucket values add up to 1 or more. Blocks without a spcified chance will be ignored", - "Generator_Bucket"), + // + BUCKET_ENTRIES_IGNORED("$2Total bucket values add up to 1 or more. Blocks without a specified chance will be ignored", "Generator_Bucket"), /** * Command Categories @@ -730,7 +636,6 @@ public enum Captions { COMMAND_CATEGORY_DEBUG("Debug", "Category"), COMMAND_CATEGORY_ADMINISTRATION("Admin", "Category"), - // GRANTED_PLOTS("$1Result: $2%s $1grants left", "Grants"), GRANTED_PLOT("$1You granted %s0 plot to $2%s1", "Grants"), @@ -740,18 +645,16 @@ public enum Captions { /** * Legacy Configuration Conversion */ - LEGACY_CONFIG_FOUND("A legacy configuration file was detected. Conversion will be attempted.", - "LegacyConfig"), LEGACY_CONFIG_BACKUP( - "A copy of worlds.yml $1have been saved in the file worlds.yml.old$1.", - "LegacyConfig"), LEGACY_CONFIG_REPLACED("> %s has been replaced with %s", - "LegacyConfig"), LEGACY_CONFIG_DONE( + LEGACY_CONFIG_FOUND("A legacy configuration file was detected. Conversion will be attempted.", "LegacyConfig"), + LEGACY_CONFIG_BACKUP("A copy of worlds.yml $1have been saved in the file worlds.yml.old$1.", "LegacyConfig"), + LEGACY_CONFIG_REPLACED("> %s has been replaced with %s", "LegacyConfig"), + LEGACY_CONFIG_DONE( "The conversion has finished. PlotSquared will now be disabled and the new configuration file will" + " be used at next startup. Please review the new worlds.yml file. " + "Please note that schematics will not be converted, as we are now using WorldEdit to handle schematics. " + "You need to re-generate the schematics.", - "LegacyConfig"), LEGACY_CONFIG_CONVERSION_FAILED( - "Failed to convert the legacy configuration file. See stack trace for information.", "LegacyConfig"), + LEGACY_CONFIG_CONVERSION_FAILED("Failed to convert the legacy configuration file. See stack trace for information.", "LegacyConfig"), CUSTOM_STRING("-", "-"); //@formatter:on From 1cf85ff2c68fff501ddd3406f4d853479254f517 Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Sat, 17 Aug 2019 02:19:29 +0200 Subject: [PATCH 10/15] Removed unused translation strings And added a new alias --- .../plotsquared/plot/commands/Delete.java | 2 +- .../plotsquared/plot/config/Captions.java | 62 +++---------------- 2 files changed, 8 insertions(+), 56 deletions(-) diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Delete.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Delete.java index 16f10b7b0..3593de74f 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Delete.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Delete.java @@ -9,7 +9,7 @@ import com.github.intellectualsites.plotsquared.plot.util.*; @CommandDeclaration(command = "delete", permission = "plots.delete", description = "Delete the plot you stand on", usage = "/plot delete", - aliases = {"dispose", "del"}, category = CommandCategory.CLAIMING, + aliases = {"dispose", "del", "unclaim"}, category = CommandCategory.CLAIMING, requiredType = RequiredType.NONE, confirmation = true) public class Delete extends SubCommand { // Note: To delete a specific plot use /plot delete diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java index 27f3fdeac..5caac5718 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/config/Captions.java @@ -223,21 +223,9 @@ public enum Captions { // BORDER("$2You are outside the current map border", "Border"), // - // - UNCLAIM_SUCCESS("$4You successfully unclaimed the plot.", "Unclaim"), - UNCLAIM_FAILED("$2Could not unclaim the plot", "Unclaim"), - // // - WORLDEDIT_DELAYED("$2Please wait while we process your WorldEdit action...", "WorldEdit Masks"), - WORLDEDIT_RUN("$2Apologies for the delay. Now executing: %s", "WorldEdit Masks"), - REQUIRE_SELECTION_IN_MASK("$2%s of your selection is not within your plot mask. You can only make edits within your plot.", "WorldEdit Masks"), - WORLDEDIT_VOLUME("$2You cannot select a volume of %current%. The maximum volume you can modify is %max%.", "WorldEdit Masks"), - WORLDEDIT_ITERATIONS("$2You cannot iterate %current% times. The maximum number of iterations allowed is %max%.", "WorldEdit Masks"), - WORLDEDIT_UNSAFE("$2Access to that command has been blocked","WorldEdit Masks"), WORLDEDIT_BYPASS("$2&oTo bypass your restrictions use $4/plot wea", "WorldEdit Masks"), WORLDEDIT_BYPASSED("$2Currently bypassing WorldEdit restriction.", "WorldEdit Masks"), - WORLDEDIT_UNMASKED("$1Your WorldEdit is now unrestricted.", "WorldEdit Masks"), - WORLDEDIT_RESTRICTED("$1Your WorldEdit is now restricted.", "WorldEdit Masks"), // // GAMEMODE_WAS_BYPASSED("$1You bypassed the gamemode ($2{gamemode}$1) $1set for $2{plot}", "GameMode"), @@ -254,7 +242,6 @@ public enum Captions { SWAP_DIMENSIONS("$2The proposed areas must have comparable dimensions", "Swap"), SWAP_SYNTAX("$2/plot swap ", "Swap"), SWAP_SUCCESS("$4Successfully swapped plots", "Swap"), - STARTED_SWAP("$2Started plot swap task. You will be notified when it finishes", "Swap"), // // INBOX_NOTIFICATION("%s unread messages. Use /plot inbox", "Comment"), @@ -274,20 +261,12 @@ public enum Captions { NOT_CONSOLE("$2For safety reasons, this command can only be executed by console.", "Console"), IS_CONSOLE("$2This command can only be executed by a player.", "Console"), // - // - INVENTORY_USAGE("&cUsage: &6{usage}", "Inventory"), INVENTORY_DESC("&cDescription: &6{desc}", "Inventory"), - INVENTORY_CATEGORY("&cCategory: &6{category}", "Inventory"), - // // - CLIPBOARD_SET("$2The current plot is now copied to your clipboard, use $1/plot paste$2 to paste it", "Clipboard"), - PASTED("$4The plot selection was successfully pasted. It has been cleared from your clipboard.", "Clipboard"), - PASTE_FAILED("$2Failed to paste the selection. Reason: $2%s", "Clipboard"), - NO_CLIPBOARD("$2You don't have a selection in your clipboard", "Clipboard"), - CLIPBOARD_INFO("$2Current Selection - Plot ID: $1%id$2, Width: $1%width$2, Total Blocks: $1%total$2", "Clipboard"), // // - TOGGLE_ENABLED("$2Enabled setting: %s", "Toggle"), TOGGLE_DISABLED("$2Disabled setting: %s", "Toggle"), + TOGGLE_ENABLED("$2Enabled setting: %s", "Toggle"), + TOGGLE_DISABLED("$2Disabled setting: %s", "Toggle"), // // COMMAND_BLOCKED("$2That command is not allowed in this plot", "Blocked Command"), @@ -366,7 +345,6 @@ public enum Captions { PREFIX_FAREWELL("$1%id%$2> ", "Titles"), // // - TASK_START("Starting task...", "Core"), PREFIX("$3[$1P2$3] $2", "Core"), ENABLED("$1%s0 is now enabled", "Core"), // @@ -377,24 +355,17 @@ public enum Captions { // DESC_SET("$2Plot description set", "Desc"), DESC_UNSET("$2Plot description unset", "Desc"), - MISSING_DESC("$2You need to specify a description", "Desc"), // // ALIAS_SET_TO("$2Plot alias set to $1%alias%", "Alias"), ALIAS_REMOVED("$2Plot alias removed", "Alias"), - MISSING_ALIAS("$2You need to specify an alias", "Alias"), ALIAS_TOO_LONG("$2The alias must be < 50 characters in length", "Alias"), ALIAS_IS_TAKEN("$2That alias is already taken", "Alias"), // // - MISSING_POSITION("$2You need to specify a position. Possible values: $1none", "Position"), POSITION_SET("$1Home position set to your current location", "Position"), POSITION_UNSET("$1Home position reset to the default location", "Position"), HOME_ARGUMENT("$2Use /plot set home [none]", "Position"), - INVALID_POSITION("$2That is not a valid position value", "Position"), - // - // - ENTITY_CAP("$2You are not allowed to spawn more mobs", "Cap"), // // NO_SCHEMATIC_PERMISSION("$2You don't have the permission required to use schematic $1%s", "Permission"), @@ -414,7 +385,6 @@ public enum Captions { MERGE_REQUEST_CONFIRM("Merge request from %s", "Permission"), NO_PERM_MERGE("$2You are not the owner of the plot: $1%plot%", "Merge"), NO_AVAILABLE_AUTOMERGE("$2You do not own any adjacent plots in the specified direction or are not allowed to merge to the required size.", "Merge"), - UNLINK_REQUIRED("$2An unlink is required to do this.", "Merge"), UNMERGE_CANCELLED("$1Unlink has been cancelled", "Merge"), UNLINK_IMPOSSIBLE("$2You can only unlink a mega-plot", "Merge"), UNLINK_SUCCESS("$2Successfully unlinked plots.", "Merge"), @@ -422,13 +392,10 @@ public enum Captions { // NOT_VALID_SUBCOMMAND("$2That is not a valid subcommand", "CommandConfig"), DID_YOU_MEAN("$2Did you mean: $1%s", "CommandConfig"), - NAME_LITTLE("$2%s0 name is too short, $1%s1$2<$1%s3", "CommandConfig"), - NO_COMMANDS("$2I'm sorry, but you're not permitted to use any subcommands.", "CommandConfig"), SUBCOMMAND_SET_OPTIONS_HEADER("$2Possible Values: ", "CommandConfig"), COMMAND_SYNTAX("$1Usage: $2%s", "CommandConfig"), // // - INVALID_PLAYER_WAIT("$2Player not found: $1%s$2, fetching it. Try again soon.", "Errors"), INVALID_PLAYER("$2Player not found: $1%s$2.", "Errors"), INVALID_PLAYER_OFFLINE("$2The player must be online: $1%s.", "Errors"), INVALID_COMMAND_FLAG("$2Invalid command flag: %s0", "Errors"), @@ -454,7 +421,6 @@ public enum Captions { // // TRIM_IN_PROGRESS("A world trim task is already in progress!", "Trim"), - NOT_VALID_HYBRID_PLOT_WORLD("The hybrid plot manager is required to perform this action", "Trim"), // // BLOCK_LIST_SEPARATOR("$1,$2 ", "Block List"), @@ -482,31 +448,23 @@ public enum Captions { DEBUG_LINE("$2>> $1%var%$2:$1 %val%&-", "Debug"), // // - NOT_VALID_DATA("$2That's not a valid data id.", "Invalid"), NOT_VALID_BLOCK("$2That's not a valid block: %s", "Invalid"), NOT_ALLOWED_BLOCK("$2That block is not allowed: %s", "Invalid"), NOT_VALID_NUMBER("$2That's not a valid number within the range: %s", "Invalid"), NOT_VALID_PLOT_ID("$2That's not a valid plot id.", "Invalid"), - PLOT_ID_FORM("$2The plot id must be in the form: $1X;Y $2e.g. $1-5;7", "Invalid"), - NOT_YOUR_PLOT("$2That is not your plot.", "Invalid"), - 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"), // // - NEED_PLOT_NUMBER("$2You've got to specify a plot number or alias", "Need"), NEED_BLOCK("$2You've got to specify a block", "Need"), - NEED_PLOT_ID("$2You've got to specify a plot id.", "Need"), - NEED_PLOT_WORLD("$2You've got to specify a plot area.", "Need"), - NEED_USER("$2You need to specify a username", "Need"), // // PLOT_NEAR("$1Players: %s0", "Near"), // // - NONE("None", "Info"), NOW("Now", "Info"), - NEVER("Never", "Info"), UNKNOWN("Unknown", "Info"), + NONE("None", "Info"), + NOW("Now", "Info"), + NEVER("Never", "Info"), + UNKNOWN("Unknown", "Info"), SERVER("Server", "Info"), EVERYONE("Everyone", "Info"), PLOT_UNOWNED("$2The current plot must have an owner to perform this action", "Info"), @@ -532,11 +490,10 @@ public enum Captions { PLOT_INFO_SEEN("$1Seen:$2 %seen%", "Info"), PLOT_USER_LIST(" $1%user%$2,", "Info"), PLOT_FLAG_LIST("$1%s0:%s1$2", "Info"), - INFO_SYNTAX_CONSOLE("$2/plot info X;Y", "Info"), + INFO_SYNTAX_CONSOLE("$2/plot info X;Z", "Info"), // // GENERATING_COMPONENT("$1Started generating component from your settings", "Working"), - CLEARING_PLOT("$2Clearing plot async.", "Working"), CLEARING_DONE("$4Clear completed! Took %sms.", "Working"), DELETING_DONE("$4Delete completed! Took %sms.", "Working"), PLOT_NOT_CLAIMED("$2Plot not claimed", "Working"), @@ -561,7 +518,6 @@ public enum Captions { PLOT_CHAT_OFF("$4Plot chat disabled.", "Chat"), // // - DENIED_REMOVED("$4You successfully undenied the player from this plot", "Deny"), DENIED_ADDED("$4You successfully denied the player from this plot", "Deny"), DENIED_NEED_ARGUMENT("$2Arguments are missing. $1/plot denied add $2or $1/plot denied remove ", "Deny"), WAS_NOT_DENIED("$2That player was not denied on this plot", "Deny"), @@ -578,7 +534,6 @@ public enum Captions { NOT_VALID_FLAG("$2That is not a valid flag", "Flag"), NOT_VALID_FLAG_SUGGESTED("$2That is not a valid flag. Did you mean: $1%s", "Flag"), NOT_VALID_VALUE("$2Flag values must be alphanumerical", "Flag"), - FLAG_NOT_IN_PLOT("$2The plot does not have that flag", "Flag"), FLAG_NOT_REMOVED("$2The flag could not be removed", "Flag"), FLAG_NOT_ADDED("$2The flag could not be added", "Flag"), FLAG_REMOVED("$4Successfully removed flag", "Flag"), @@ -587,8 +542,6 @@ public enum Captions { // // TRUSTED_ADDED("$4You successfully trusted a user to the plot", "Trusted"), - TRUSTED_REMOVED("$4You successfully removed a trusted user from the plot", "Trusted"), - WAS_NOT_ADDED("$2That player was not trusted on this plot", "Trusted"), PLOT_REMOVED_USER("$1Plot %s of which you were added to has been deleted due to owner inactivity", "Trusted"), // // @@ -596,7 +549,6 @@ public enum Captions { ALREADY_OWNER("$2That user is already the plot owner: %s0", "Member"), ALREADY_ADDED("$2That user is already added to that category: %s0", "Member"), MEMBER_ADDED("$4That user can now build while the plot owner is online", "Member"), - MEMBER_REMOVED("$1You successfully removed a user from the plot", "Member"), MEMBER_WAS_NOT_ADDED("$2That player was not added as a user on this plot", "Member"), PLOT_MAX_MEMBERS("$2You are not allowed to add any more players to this plot", "Member"), // From c6a420626631b7f85634ba1235bd77cbbf833dcb Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Sat, 17 Aug 2019 17:06:17 +0200 Subject: [PATCH 11/15] Fix Typo --- .../plotsquared/plot/generator/HybridUtils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/generator/HybridUtils.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/generator/HybridUtils.java index 135149279..84c487bdb 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/generator/HybridUtils.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/generator/HybridUtils.java @@ -183,7 +183,7 @@ public abstract class HybridUtils { ChunkLoc loc = iterator.next(); iterator.remove(); PlotSquared.debug("&3Updating .mcr: " + loc.x + ", " + loc.z - + " (aprrox 1024 chunks)"); + + " (approx 1024 chunks)"); PlotSquared.debug(" - Remaining: " + regions.size()); chunks.addAll(getChunks(loc)); System.gc(); From 59a1d619d3fdf825b207987f936fbbd3adaeea6c Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Sun, 18 Aug 2019 14:29:37 +0200 Subject: [PATCH 12/15] Add sponsors --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index 85ceaea93..5ff94de6d 100644 --- a/README.md +++ b/README.md @@ -65,3 +65,9 @@ Suggestions are welcome! We have a separate issue tracker for suggestions, that * [PlotSquaredMG](https://www.spigotmc.org/resources/plotsquaredmg.8025/) * [BasicPlots](https://www.spigotmc.org/resources/basicplots.6901/) * [HoloPlots](https://www.spigotmc.org/resources/holoplots.4880/) + +# Sponsors +

+

+

+

From 08cd39749b47f6ff3843803d98ea11c3a4250e10 Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Tue, 27 Aug 2019 14:44:56 +0200 Subject: [PATCH 13/15] Create PULL_REQUEST_TEMPLATE.md --- .github/PULL_REQUEST_TEMPLATE.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 .github/PULL_REQUEST_TEMPLATE.md diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md new file mode 100644 index 000000000..1ccb63862 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,17 @@ +## Overview + + +**Fixes #{issue number}** + +## Description + +## Checklist + +- [] I included all information required in the sections above +- [] I tested my changes and approved their functionality +- [] I ensured my changes do not break other parts of the code +- [] I read and followed the [contribution guidelines](https://github.com/IntellectualSites/PlotSquared/blob/breaking/CONTRIBUTING.md) \ No newline at end of file From e1db27010c60d8dc4dd45ba5bc5b232c9c73612a Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Wed, 4 Sep 2019 03:01:25 +0200 Subject: [PATCH 14/15] Updating command usage formats --- .../intellectualsites/plotsquared/plot/commands/Alias.java | 4 ++-- .../plotsquared/plot/commands/Condense.java | 3 ++- .../plotsquared/plot/commands/Continue.java | 2 +- .../plotsquared/plot/commands/Database.java | 4 ++-- .../plotsquared/plot/commands/FlagCmd.java | 5 ++--- .../intellectualsites/plotsquared/plot/commands/Inbox.java | 6 ++---- .../intellectualsites/plotsquared/plot/commands/Owner.java | 2 +- .../plotsquared/plot/commands/SchematicCmd.java | 2 +- .../plotsquared/plot/commands/Template.java | 3 +-- .../intellectualsites/plotsquared/plot/commands/Toggle.java | 4 +++- 10 files changed, 17 insertions(+), 18 deletions(-) diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Alias.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Alias.java index 7f335cfa5..e4a719dcf 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Alias.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Alias.java @@ -21,7 +21,7 @@ import com.github.intellectualsites.plotsquared.plot.util.UUIDHandler; @Override public boolean onCommand(PlotPlayer player, String[] args) { if (args.length == 0) { - Captions.COMMAND_SYNTAX.send(player, "/plot alias "); + Captions.COMMAND_SYNTAX.send(player, getUsage()); return false; } @@ -64,7 +64,7 @@ import com.github.intellectualsites.plotsquared.plot.util.UUIDHandler; } break; default: - Captions.COMMAND_SYNTAX.send(player, "/plot alias "); + Captions.COMMAND_SYNTAX.send(player, getUsage()); result = false; } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Condense.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Condense.java index 184e2289d..a9341f373 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Condense.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Condense.java @@ -20,6 +20,7 @@ import java.util.Set; import java.util.concurrent.atomic.AtomicBoolean; @CommandDeclaration(command = "condense", permission = "plots.admin", + usage = "/plot condense [radius]", description = "Condense a plotworld", category = CommandCategory.ADMINISTRATION, requiredType = RequiredType.CONSOLE) public class Condense extends SubCommand { @@ -27,7 +28,7 @@ import java.util.concurrent.atomic.AtomicBoolean; @Override public boolean onCommand(final PlotPlayer player, String[] args) { if (args.length != 2 && args.length != 3) { - MainUtil.sendMessage(player, "/plot condense [radius]"); + MainUtil.sendMessage(player, getUsage()); return false; } PlotArea area = PlotSquared.get().getPlotAreaByString(args[0]); diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Continue.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Continue.java index 4aec2d6d0..961742c1b 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Continue.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Continue.java @@ -12,7 +12,7 @@ import com.github.intellectualsites.plotsquared.plot.util.Permissions; @CommandDeclaration(command = "continue", description = "Continue a plot that was previously marked as done", permission = "plots.continue", category = CommandCategory.SETTINGS, - requiredType = RequiredType.NONE) public class Continue extends SubCommand { + requiredType = RequiredType.PLAYER) public class Continue extends SubCommand { @Override public boolean onCommand(PlotPlayer player, String[] args) { Plot plot = player.getCurrentPlot(); diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Database.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Database.java index d908f2105..abbddc9ca 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Database.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Database.java @@ -48,7 +48,7 @@ import java.util.Map.Entry; @Override public boolean onCommand(final PlotPlayer player, String[] args) { if (args.length < 1) { - MainUtil.sendMessage(player, "/plot database [area] "); + MainUtil.sendMessage(player, getUsage()); return false; } List plots; @@ -60,7 +60,7 @@ import java.util.Map.Entry; plots = PlotSquared.get().sortPlotsByTemp(PlotSquared.get().getPlots()); } if (args.length < 1) { - MainUtil.sendMessage(player, "/plot database [world] "); + MainUtil.sendMessage(player, getUsage()); MainUtil.sendMessage(player, "[arg] indicates an optional argument"); return false; } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/FlagCmd.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/FlagCmd.java index 470d8d605..b55895494 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/FlagCmd.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/FlagCmd.java @@ -87,8 +87,7 @@ import java.util.*; * plot flag list */ if (args.length == 0) { - MainUtil.sendMessage(player, Captions.COMMAND_SYNTAX, - "/plot flag "); + MainUtil.sendMessage(player, Captions.COMMAND_SYNTAX, getUsage()); return false; } Location loc = player.getLocation(); @@ -311,7 +310,7 @@ import java.util.*; return true; } MainUtil - .sendMessage(player, Captions.COMMAND_SYNTAX, "/plot flag "); + .sendMessage(player, Captions.COMMAND_SYNTAX, getUsage()); return false; } } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Inbox.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Inbox.java index 8d427bbcd..c0c898205 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Inbox.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Inbox.java @@ -71,8 +71,7 @@ import java.util.List; return false; } if (args.length == 0) { - sendMessage(player, Captions.COMMAND_SYNTAX, - "/plot inbox [inbox] [delete |clear|page]"); + sendMessage(player, Captions.COMMAND_SYNTAX, getUsage()); for (final CommentInbox inbox : CommentManager.inboxes.values()) { if (inbox.canRead(plot, player)) { if (!inbox.getComments(plot, new RunnableVal>() { @@ -172,8 +171,7 @@ import java.util.List; try { page = Integer.parseInt(args[1]); } catch (NumberFormatException ignored) { - sendMessage(player, Captions.COMMAND_SYNTAX, - "/plot inbox [inbox] [delete |clear|page]"); + sendMessage(player, Captions.COMMAND_SYNTAX, getUsage()); return false; } } diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Owner.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Owner.java index 55dbdbda4..98e32dcd6 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Owner.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Owner.java @@ -17,7 +17,7 @@ import java.util.UUID; @CommandDeclaration(command = "setowner", permission = "plots.set.owner", description = "Set the plot owner", usage = "/plot setowner ", aliases = {"owner", "so", "seto"}, category = CommandCategory.CLAIMING, - requiredType = RequiredType.NONE, confirmation = true) public class Owner extends SetCommand { + requiredType = RequiredType.PLAYER, confirmation = true) public class Owner extends SetCommand { @Override public boolean set(final PlotPlayer player, final Plot plot, String value) { Set plots = plot.getConnectedPlots(); diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SchematicCmd.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SchematicCmd.java index f654fa776..deef2081c 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SchematicCmd.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/SchematicCmd.java @@ -25,7 +25,7 @@ import java.util.UUID; @CommandDeclaration(command = "schematic", permission = "plots.schematic", description = "Schematic command", aliases = {"sch", "schem"}, - category = CommandCategory.SCHEMATIC, usage = "/plot schematic ") + category = CommandCategory.SCHEMATIC, usage = "/plot schematic ") public class SchematicCmd extends SubCommand { private boolean running = false; diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Template.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Template.java index eb96f78cc..563956c46 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Template.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Template.java @@ -113,8 +113,7 @@ import java.util.zip.ZipOutputStream; return true; } } - MainUtil.sendMessage(player, Captions.COMMAND_SYNTAX, - "/plot template [template]"); + MainUtil.sendMessage(player, Captions.COMMAND_SYNTAX, getUsage()); return true; } final String world = args[1]; diff --git a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Toggle.java b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Toggle.java index e19d81762..efe54f3d8 100644 --- a/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Toggle.java +++ b/Core/src/main/java/com/github/intellectualsites/plotsquared/plot/commands/Toggle.java @@ -9,14 +9,16 @@ import com.github.intellectualsites.plotsquared.plot.object.RunnableVal3; import com.github.intellectualsites.plotsquared.plot.util.MainUtil; @CommandDeclaration(command = "toggle", aliases = {"attribute"}, permission = "plots.use", + usage = "/plot toggle ", description = "Toggle per user settings", requiredType = RequiredType.NONE, category = CommandCategory.SETTINGS) public class Toggle extends Command { + public Toggle() { super(MainCommand.getInstance(), true); } @CommandDeclaration(command = "chatspy", aliases = {"spy"}, - permission = "plots.admin.command.chat", description = "Toggle admin chat spying") + permission = "plots.admin.command.chat", description = "Toggle plot chat spy") public void chatspy(Command command, PlotPlayer player, String[] args, RunnableVal3 confirm, RunnableVal2 whenDone) { From 4d0bd8a3a35956e3bd5824d456bd703d0344945c Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Wed, 4 Sep 2019 03:04:51 +0200 Subject: [PATCH 15/15] Upgrade build files --- Bukkit/build.gradle | 2 +- Core/build.gradle | 10 +++++----- build.gradle | 12 ++++++------ 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/Bukkit/build.gradle b/Bukkit/build.gradle index 5fe453bd7..237c0740e 100644 --- a/Bukkit/build.gradle +++ b/Bukkit/build.gradle @@ -22,7 +22,7 @@ dependencies { implementation("org.spigotmc:spigot-api:1.14.4-R0.1-SNAPSHOT") compile(group: "com.sk89q.worldedit", name: "worldedit-bukkit", version: "7.0.0") compile("io.papermc:paperlib:1.0.2") - implementation ("net.kyori:text-adapter-bukkit:3.0.3") + implementation("net.kyori:text-adapter-bukkit:3.0.3") compile("net.milkbowl.vault:VaultAPI:1.7") { exclude(module: "bukkit") } diff --git a/Core/build.gradle b/Core/build.gradle index 3cbf8f555..53f305992 100644 --- a/Core/build.gradle +++ b/Core/build.gradle @@ -5,7 +5,7 @@ def textVersion = "3.0.2" dependencies { implementation("org.yaml:snakeyaml:1.23") - implementation ("com.google.code.gson:gson:2.8.0") { + implementation("com.google.code.gson:gson:2.8.0") { because("Minecraft uses GSON 2.8.0") force = true } @@ -14,10 +14,10 @@ dependencies { testCompileOnly("org.projectlombok:lombok:1.18.8") annotationProcessor("org.projectlombok:lombok:1.18.8") testAnnotationProcessor("org.projectlombok:lombok:1.18.8") - implementation ("com.github.Sauilitired:Jenkins4J:2.0-SNAPSHOT") - implementation ("com.squareup.okhttp3:okhttp:3.14.0") - implementation ("com.squareup.okio:okio:2.2.2") - implementation ("org.jetbrains.kotlin:kotlin-stdlib:1.3.30") + implementation("com.github.Sauilitired:Jenkins4J:2.0-SNAPSHOT") + implementation("com.squareup.okhttp3:okhttp:3.14.0") + implementation("com.squareup.okio:okio:2.2.2") + implementation("org.jetbrains.kotlin:kotlin-stdlib:1.3.30") } sourceCompatibility = 1.8 diff --git a/build.gradle b/build.gradle index 64a344f80..f2afef586 100644 --- a/build.gradle +++ b/build.gradle @@ -32,11 +32,11 @@ ext { git = Grgit.open(dir: new File(rootDir.toString() + "/.git")) date = git.head().getDate().format("yy.MM.dd") revision = "-${git.head().abbreviatedId}" - parents = git.head().parentIds; + parents = git.head().parentIds if (project.hasProperty("buildnumber")) { buildNumber = "$buildnumber" } else { - index = -2042; // Offset to match CI + index = -2042 // Offset to match CI for (; parents != null && !parents.isEmpty(); index++) { parents = git.getResolve().toCommit(parents.get(0)).getParentIds() } @@ -67,10 +67,10 @@ subprojects { exclude(module: "mockito-core") exclude(module: "dummypermscompat") } - implementation ("net.kyori:text-api:3.0.2") - implementation ("net.kyori:text-serializer-gson:3.0.2") - implementation ("net.kyori:text-serializer-legacy:3.0.2") - implementation ("net.kyori:text-serializer-plain:3.0.2") + implementation("net.kyori:text-api:3.0.2") + implementation("net.kyori:text-serializer-gson:3.0.2") + implementation("net.kyori:text-serializer-legacy:3.0.2") + implementation("net.kyori:text-serializer-plain:3.0.2") implementation("com.google.guava:guava:21.0") { because("Minecraft uses Guava 21 as of 1.13") }