From 7d4cb06fbe1581ceb9bedddfc471c076ac39010a Mon Sep 17 00:00:00 2001 From: AJ Ferguson Date: Wed, 13 Nov 2019 17:26:45 -0900 Subject: [PATCH] Fix crash on login --- .../connector/network/session/GeyserSession.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/connector/src/main/java/org/geysermc/connector/network/session/GeyserSession.java b/connector/src/main/java/org/geysermc/connector/network/session/GeyserSession.java index 0a619e92f..b5be8cbce 100644 --- a/connector/src/main/java/org/geysermc/connector/network/session/GeyserSession.java +++ b/connector/src/main/java/org/geysermc/connector/network/session/GeyserSession.java @@ -40,6 +40,7 @@ import com.nukkitx.math.vector.Vector2f; import com.nukkitx.math.vector.Vector2i; import com.nukkitx.math.vector.Vector3f; import com.nukkitx.math.vector.Vector3i; +import com.nukkitx.nbt.tag.CompoundTag; import com.nukkitx.protocol.bedrock.BedrockServerSession; import com.nukkitx.protocol.bedrock.data.GamePublishSetting; import com.nukkitx.protocol.bedrock.data.GameRule; @@ -150,8 +151,12 @@ public class GeyserSession implements Player { } } - upstream.sendPacket(new BiomeDefinitionListPacket()); - upstream.sendPacket(new AvailableEntityIdentifiersPacket()); + BiomeDefinitionListPacket biomePacket = new BiomeDefinitionListPacket(); + biomePacket.setTag(CompoundTag.EMPTY); + upstream.sendPacket(biomePacket); + AvailableEntityIdentifiersPacket entityPacket = new AvailableEntityIdentifiersPacket(); + entityPacket.setTag(CompoundTag.EMPTY); + upstream.sendPacket(entityPacket); PlayStatusPacket playStatusPacket = new PlayStatusPacket(); playStatusPacket.setStatus(PlayStatusPacket.Status.PLAYER_SPAWN);