Paper/patches/server/0849-Fix-text-display-error-on-spawn.patch

20 lines
1.3 KiB
Diff
Raw Normal View History

2023-09-22 18:11:35 +02:00
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
From: Nassim Jahnke <nassim@njahnke.dev>
Date: Thu, 16 Mar 2023 16:27:50 +0100
Subject: [PATCH] Fix text display error on spawn
diff --git a/src/main/java/net/minecraft/world/entity/Display.java b/src/main/java/net/minecraft/world/entity/Display.java
index dcbaa06f807ba3c1b64c96b3c2dd84d46d6be751..2ecd3ed5b36475125c6f63af2612011fc8fba8a5 100644
2023-09-22 18:11:35 +02:00
--- a/src/main/java/net/minecraft/world/entity/Display.java
+++ b/src/main/java/net/minecraft/world/entity/Display.java
2023-12-06 17:21:56 +01:00
@@ -864,7 +864,7 @@ public abstract class Display extends Entity {
2023-09-22 18:11:35 +02:00
byte b = loadFlag((byte)0, nbt, "shadow", (byte)1);
b = loadFlag(b, nbt, "see_through", (byte)2);
b = loadFlag(b, nbt, "default_background", (byte)4);
- Optional<Display.TextDisplay.Align> optional = Display.TextDisplay.Align.CODEC.decode(NbtOps.INSTANCE, nbt.get("alignment")).resultOrPartial(Util.prefix("Display entity", Display.LOGGER::error)).map(Pair::getFirst);
+ Optional<Display.TextDisplay.Align> optional = Display.TextDisplay.Align.CODEC.decode(NbtOps.INSTANCE, nbt.get("alignment")).result().map(Pair::getFirst); // Paper - Hide text display error on spawn
2023-09-22 18:11:35 +02:00
if (optional.isPresent()) {
byte var10000;
switch ((Display.TextDisplay.Align)optional.get()) {