From 11d9d30050a0b8474ca5e6073e013d5f6c5aced2 Mon Sep 17 00:00:00 2001 From: Camotoy <20743703+DoctorMacc@users.noreply.github.com> Date: Fri, 27 Nov 2020 17:56:32 -0500 Subject: [PATCH] Fix mounts being unmountable with cache chunks (#1576) Teleports need to be confirmed before riding --- .../bedrock/BedrockMoveEntityAbsoluteTranslator.java | 5 +++-- .../translators/bedrock/BedrockPlayerInputTranslator.java | 4 +++- .../java/entity/JavaEntitySetPassengersTranslator.java | 4 ++++ 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/connector/src/main/java/org/geysermc/connector/network/translators/bedrock/BedrockMoveEntityAbsoluteTranslator.java b/connector/src/main/java/org/geysermc/connector/network/translators/bedrock/BedrockMoveEntityAbsoluteTranslator.java index 26d7f1d46..fd5e71e97 100644 --- a/connector/src/main/java/org/geysermc/connector/network/translators/bedrock/BedrockMoveEntityAbsoluteTranslator.java +++ b/connector/src/main/java/org/geysermc/connector/network/translators/bedrock/BedrockMoveEntityAbsoluteTranslator.java @@ -31,13 +31,14 @@ import org.geysermc.connector.network.session.GeyserSession; import org.geysermc.connector.network.translators.PacketTranslator; import org.geysermc.connector.network.translators.Translator; -// Used for horses +/** + * Sent by the client when moving a horse. + */ @Translator(packet = MoveEntityAbsolutePacket.class) public class BedrockMoveEntityAbsoluteTranslator extends PacketTranslator { @Override public void translate(MoveEntityAbsolutePacket packet, GeyserSession session) { - ClientVehicleMovePacket clientVehicleMovePacket = new ClientVehicleMovePacket( packet.getPosition().getX(), packet.getPosition().getY(), packet.getPosition().getZ(), packet.getRotation().getY() - 90, packet.getRotation().getX() diff --git a/connector/src/main/java/org/geysermc/connector/network/translators/bedrock/BedrockPlayerInputTranslator.java b/connector/src/main/java/org/geysermc/connector/network/translators/bedrock/BedrockPlayerInputTranslator.java index 2bd46c7ce..73b91e2f8 100644 --- a/connector/src/main/java/org/geysermc/connector/network/translators/bedrock/BedrockPlayerInputTranslator.java +++ b/connector/src/main/java/org/geysermc/connector/network/translators/bedrock/BedrockPlayerInputTranslator.java @@ -31,7 +31,9 @@ import org.geysermc.connector.network.session.GeyserSession; import org.geysermc.connector.network.translators.PacketTranslator; import org.geysermc.connector.network.translators.Translator; -// Makes minecarts respond to player input +/** + * Sent by the client for minecarts and boats. + */ @Translator(packet = PlayerInputPacket.class) public class BedrockPlayerInputTranslator extends PacketTranslator { diff --git a/connector/src/main/java/org/geysermc/connector/network/translators/java/entity/JavaEntitySetPassengersTranslator.java b/connector/src/main/java/org/geysermc/connector/network/translators/java/entity/JavaEntitySetPassengersTranslator.java index 0fecf118e..a3128dabf 100644 --- a/connector/src/main/java/org/geysermc/connector/network/translators/java/entity/JavaEntitySetPassengersTranslator.java +++ b/connector/src/main/java/org/geysermc/connector/network/translators/java/entity/JavaEntitySetPassengersTranslator.java @@ -61,6 +61,10 @@ public class JavaEntitySetPassengersTranslator extends PacketTranslator