mirror of
https://github.com/ViaVersion/ViaVersion.git
synced 2024-12-23 08:57:39 +01:00
Fix sign nbt on 1.20 client (#3436)
This commit is contained in:
parent
8a0e187621
commit
f91e6a83f9
@ -172,17 +172,19 @@ public final class InventoryPackets extends ItemRewriter<ClientboundPackets1_19_
|
||||
|
||||
final ListTag messages = new ListTag(StringTag.class);
|
||||
for (int i = 1; i < 5; i++) {
|
||||
final Tag text = tag.get("Text" + i);
|
||||
final Tag text = tag.remove("Text" + i);
|
||||
messages.add(text != null ? text : new StringTag(ChatRewriter.emptyComponentString()));
|
||||
}
|
||||
frontText.put("messages", messages);
|
||||
|
||||
final ListTag filteredMessages = new ListTag(StringTag.class);
|
||||
for (int i = 1; i < 5; i++) {
|
||||
final Tag text = tag.get("FilteredText" + i);
|
||||
filteredMessages.add(text != null ? text : new StringTag(ChatRewriter.emptyComponentString()));
|
||||
final Tag text = tag.remove("FilteredText" + i);
|
||||
filteredMessages.add(text != null ? text : messages.get(i - 1));
|
||||
}
|
||||
if (!filteredMessages.equals(messages)) {
|
||||
frontText.put("filtered_messages", filteredMessages);
|
||||
}
|
||||
frontText.put("filtered_messages", filteredMessages);
|
||||
|
||||
final Tag color = tag.remove("Color");
|
||||
if (color != null) {
|
||||
|
Loading…
Reference in New Issue
Block a user