Add missing translation for argument pipe color (#4480)

This commit is contained in:
Josh Roy 2021-08-26 13:09:16 -07:00 committed by GitHub
parent c746a1ce17
commit df88a89c14
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 1 deletions

View File

@ -69,7 +69,7 @@ public abstract class EssentialsCommand implements IEssentialsCommand {
final Matcher matcher = ARGUMENT_PATTERN.matcher(usage);
while (matcher.find()) {
final String color = matcher.group(3).equals("<") ? tl("commandArgumentRequired") : tl("commandArgumentOptional");
matcher.appendReplacement(buffer, "$1" + color + matcher.group(2).replace("|", ChatColor.RED + "|" + color) + ChatColor.RESET);
matcher.appendReplacement(buffer, "$1" + color + matcher.group(2).replace("|", tl("commandArgumentOr") + "|" + color) + ChatColor.RESET);
}
matcher.appendTail(buffer);
usageStrings.put(buffer.toString(), description);

View File

@ -143,6 +143,7 @@ clearinventoryCommandUsage3Description=Clears all (or the specified amount) of t
clearinventoryconfirmtoggleCommandDescription=Toggles whether you are prompted to confirm inventory clears.
clearinventoryconfirmtoggleCommandUsage=/<command>
commandArgumentOptional=\u00a77
commandArgumentOr=\u00a7c
commandArgumentRequired=\u00a7e
commandCooldown=\u00a7cYou cannot type that command for {0}.
commandDisabled=\u00a7cThe command\u00a76 {0}\u00a7c is disabled.