MC 1.14.1

This commit is contained in:
Zach Brown
2019-05-13 21:20:58 -05:00
parent d1310ddac5
commit 1ea2c3b4be
256 changed files with 762 additions and 787 deletions

View File

@@ -20,12 +20,12 @@ think of no reason to use it.
Fixes GH-1571
diff --git a/src/main/java/net/minecraft/server/TileEntitySign.java b/src/main/java/net/minecraft/server/TileEntitySign.java
index 9de03a24cf..4165c6d11a 100644
index 626ba9b17..7b5d534f4 100644
--- a/src/main/java/net/minecraft/server/TileEntitySign.java
+++ b/src/main/java/net/minecraft/server/TileEntitySign.java
@@ -0,0 +0,0 @@ public class TileEntitySign extends TileEntity implements ICommandListener { //
private final String[] k = new String[4];
private EnumColor l;
private EnumColor color;
+ // Paper start - Strip invalid unicode from signs on load
+ private static final boolean keepInvalidUnicode = Boolean.getBoolean("Paper.keepInvalidUnicode"); // Allow people to keep their bad unicode if they really want it
@@ -34,13 +34,12 @@ index 9de03a24cf..4165c6d11a 100644
+
public TileEntitySign() {
super(TileEntityTypes.SIGN);
this.l = EnumColor.BLACK;
this.color = EnumColor.BLACK;
@@ -0,0 +0,0 @@ public class TileEntitySign extends TileEntity implements ICommandListener { //
// CraftBukkit end
nbttagcompound.setString("Color", this.l.b());
+
+ // Paper start - Only remove private area unicode once
nbttagcompound.setString("Color", this.color.b());
+ // Paper start - Only remove private area unicode once // TODO - this doesn't need to run for every sign, check data ver
+ if (this.privateUnicodeRemoved) {
+ nbttagcompound.setBoolean("Paper.RemovedPrivateUnicode", true);
+ }
@@ -51,7 +50,7 @@ index 9de03a24cf..4165c6d11a 100644
@@ -0,0 +0,0 @@ public class TileEntitySign extends TileEntity implements ICommandListener { //
super.load(nbttagcompound);
this.l = EnumColor.a(nbttagcompound.getString("Color"), EnumColor.BLACK);
this.color = EnumColor.a(nbttagcompound.getString("Color"), EnumColor.BLACK);
+ // Paper start - Keep track, only do it once per sign
+ this.privateUnicodeRemoved = nbttagcompound.getBoolean("Paper.RemovedPrivateUnicode");
@@ -79,7 +78,7 @@ index 9de03a24cf..4165c6d11a 100644
+ // Paper end
+
try {
//IChatBaseComponent ichatbasecomponent = IChatBaseComponent.ChatSerializer.a(s); // Paper - move down - the old format might throw a json error
//IChatBaseComponent ichatbasecomponent = IChatBaseComponent.ChatSerializer.a(s.isEmpty() ? "\"\"" : s); // Paper - move down - the old format might throw a json error
@@ -0,0 +0,0 @@ public class TileEntitySign extends TileEntity implements ICommandListener { //
this.k[i] = null;