diff --git a/connector/pom.xml b/connector/pom.xml index c65e73b51..c12c0d24f 100644 --- a/connector/pom.xml +++ b/connector/pom.xml @@ -11,7 +11,7 @@ connector - 4.9.2 + 3d6eaaf63f 8.5.2 2.12.4 4.1.66.Final @@ -160,6 +160,10 @@ com.github.steveice10 mcauthlib + + net.kyori + * + @@ -223,7 +227,20 @@ - net.kyori + com.github.KyoriPowered.adventure + adventure-text-serializer-gson + ${adventure.version} + compile + + + com.github.KyoriPowered.adventure + adventure-text-serializer-gson-legacy-impl + ${adventure.version} + compile + + + + com.github.KyoriPowered.adventure adventure-text-serializer-legacy ${adventure.version} compile diff --git a/connector/src/main/java/org/geysermc/connector/network/translators/item/translators/nbt/BasicItemTranslator.java b/connector/src/main/java/org/geysermc/connector/network/translators/item/translators/nbt/BasicItemTranslator.java index 58d72de0e..b6b1dfac6 100644 --- a/connector/src/main/java/org/geysermc/connector/network/translators/item/translators/nbt/BasicItemTranslator.java +++ b/connector/src/main/java/org/geysermc/connector/network/translators/item/translators/nbt/BasicItemTranslator.java @@ -56,10 +56,10 @@ public class BasicItemTranslator extends NbtItemStackTranslator { return; } - ListTag loreTag = displayTag.get("Lore"); - if (loreTag != null) { + Tag loreTag = displayTag.get("Lore"); + if (loreTag instanceof ListTag listTag) { List lore = new ArrayList<>(); - for (Tag tag : loreTag.getValue()) { + for (Tag tag : listTag.getValue()) { if (!(tag instanceof StringTag)) continue; lore.add(new StringTag("", MessageTranslator.convertMessageLenient(((StringTag) tag).getValue(), session.getLocale()))); }