From 6c2d43d7f9c8d5ce79abc88bacb79614cfc6d512 Mon Sep 17 00:00:00 2001 From: Nassim Jahnke Date: Tue, 9 Jan 2024 17:19:19 +0100 Subject: [PATCH] Handle 1.20->1.20.2 tags --- .../protocol/protocol1_20to1_20_2/Protocol1_20To1_20_2.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/common/src/main/java/com/viaversion/viabackwards/protocol/protocol1_20to1_20_2/Protocol1_20To1_20_2.java b/common/src/main/java/com/viaversion/viabackwards/protocol/protocol1_20to1_20_2/Protocol1_20To1_20_2.java index e1429437..df7bf0a2 100644 --- a/common/src/main/java/com/viaversion/viabackwards/protocol/protocol1_20to1_20_2/Protocol1_20To1_20_2.java +++ b/common/src/main/java/com/viaversion/viabackwards/protocol/protocol1_20to1_20_2/Protocol1_20To1_20_2.java @@ -43,6 +43,7 @@ import com.viaversion.viaversion.protocols.protocol1_20_2to1_20.packet.Clientbou import com.viaversion.viaversion.protocols.protocol1_20_2to1_20.packet.ClientboundPackets1_20_2; import com.viaversion.viaversion.protocols.protocol1_20_2to1_20.packet.ServerboundConfigurationPackets1_20_2; import com.viaversion.viaversion.protocols.protocol1_20_2to1_20.packet.ServerboundPackets1_20_2; +import com.viaversion.viaversion.rewriter.TagRewriter; import java.util.UUID; public final class Protocol1_20To1_20_2 extends BackwardsProtocol { @@ -59,6 +60,9 @@ public final class Protocol1_20To1_20_2 extends BackwardsProtocol tagRewriter = new TagRewriter<>(this); + tagRewriter.registerGeneric(ClientboundPackets1_20_2.TAGS); + final SoundRewriter soundRewriter = new SoundRewriter<>(this); soundRewriter.register1_19_3Sound(ClientboundPackets1_20_2.SOUND); soundRewriter.registerSound(ClientboundPackets1_20_2.ENTITY_SOUND); @@ -148,6 +152,7 @@ public final class Protocol1_20To1_20_2 extends BackwardsProtocol { + tagRewriter.getGenericHandler().handle(wrapper); wrapper.user().get(ConfigurationPacketStorage.class).addRawPacket(wrapper, ClientboundPackets1_19_4.TAGS); wrapper.cancel(); });