mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-23 11:06:29 +01:00
Apply strict limits on the length of sign text
This commit is contained in:
parent
a2d26409f7
commit
5d84673655
@ -13,7 +13,7 @@
|
||||
this.i.b(nbttagcompound);
|
||||
}
|
||||
|
||||
@@ -65,12 +71,24 @@
|
||||
@@ -65,12 +71,27 @@
|
||||
public void a(CommandObjectiveExecutor.EnumCommandResult commandobjectiveexecutor_enumcommandresult, int i) {}
|
||||
};
|
||||
|
||||
@ -25,6 +25,9 @@
|
||||
+
|
||||
for (int i = 0; i < 4; ++i) {
|
||||
String s = nbttagcompound.getString("Text" + (i + 1));
|
||||
+ if (s != null && s.length() > 384) {
|
||||
+ s = "\"\"";
|
||||
+ }
|
||||
|
||||
try {
|
||||
IChatBaseComponent ichatbasecomponent = IChatBaseComponent.ChatSerializer.a(s);
|
||||
@ -38,7 +41,7 @@
|
||||
try {
|
||||
this.lines[i] = ChatComponentUtils.filterForDisplay(icommandlistener, ichatbasecomponent, (Entity) null);
|
||||
} catch (CommandException commandexception) {
|
||||
@@ -155,7 +173,10 @@
|
||||
@@ -155,7 +176,10 @@
|
||||
ChatClickable chatclickable = chatmodifier.h();
|
||||
|
||||
if (chatclickable.a() == ChatClickable.EnumClickAction.RUN_COMMAND) {
|
||||
|
Loading…
Reference in New Issue
Block a user