Fixed item names containing vertical bars displaying incorrectly (fixes #450)

This commit is contained in:
Intelli 2023-09-25 14:27:02 -06:00
parent d944c2bd89
commit e49913bc09
4 changed files with 7 additions and 2 deletions

View file

@ -17,6 +17,7 @@ public final class Chat {
public static final String COMPONENT_TAG_CLOSE = "</COMPONENT>";
public static final String COMPONENT_COMMAND = "COMMAND";
public static final String COMPONENT_POPUP = "POPUP";
public static final String COMPONENT_PIPE = "<PIPE/>";
private Chat() {
throw new IllegalStateException("Utility class");

View file

@ -304,7 +304,7 @@ public class Util extends Queue {
StringBuilder message = new StringBuilder(Chat.COMPONENT_TAG_OPEN + Chat.COMPONENT_POPUP);
// tooltip
message.append("|" + tooltip + "|");
message.append("|" + tooltip.replace("|", Chat.COMPONENT_PIPE) + "|");
// chat output
message.append(phrase);