From 1de6bbc9dc3d554b8bab64a68592b81f70af795e Mon Sep 17 00:00:00 2001 From: Dan Mulloy Date: Sun, 11 Sep 2016 16:52:45 -0400 Subject: [PATCH] Make sure we use the update sign packet when it exists Should fix #263 --- .../com/comphenix/protocol/PacketType.java | 24 ++++++++++++++----- .../protocol/events/PacketContainer.java | 3 +-- 2 files changed, 19 insertions(+), 8 deletions(-) diff --git a/modules/API/src/main/java/com/comphenix/protocol/PacketType.java b/modules/API/src/main/java/com/comphenix/protocol/PacketType.java index 772c8dde..43841a6f 100644 --- a/modules/API/src/main/java/com/comphenix/protocol/PacketType.java +++ b/modules/API/src/main/java/com/comphenix/protocol/PacketType.java @@ -189,19 +189,19 @@ public class PacketType implements Serializable, Cloneable, Comparable { private static final EquivalentConverter DELEGATE; static { - Class packetClass = PacketType.Play.Server.UPDATE_SIGN.getPacketClass(); - if (packetClass.getName().contains("Sign")) { + if (!PacketType.Play.Server.UPDATE_SIGN.isDeprecated()) { DELEGATE = new LegacyComponentConverter(); } else { DELEGATE = new NBTComponentConverter();