From ca141bb131e87d598ffc6e65c3fb140f94929a7f Mon Sep 17 00:00:00 2001 From: Kelsi Date: Tue, 10 Mar 2026 11:33:47 -0700 Subject: [PATCH] net: send CMSG_MOVE_FLIGHT_ACK in response to SMSG_MOVE_SET/UNSET_FLIGHT SMSG_MOVE_SET_FLIGHT and SMSG_MOVE_UNSET_FLIGHT were previously consumed silently without sending the required ack. Most server implementations expect CMSG_MOVE_FLIGHT_ACK before toggling the FLYING movement flag on the player; without it the server may not grant or revoke flight state. Also updates movementInfo.flags so subsequent movement packets reflect the FLYING flag correctly. --- src/game/game_handler.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/game/game_handler.cpp b/src/game/game_handler.cpp index 35097034..ada42a6d 100644 --- a/src/game/game_handler.cpp +++ b/src/game/game_handler.cpp @@ -5540,10 +5540,16 @@ void GameHandler::handlePacket(network::Packet& packet) { case Opcode::SMSG_MOVE_SET_CAN_TRANSITION_BETWEEN_SWIM_AND_FLY: case Opcode::SMSG_MOVE_UNSET_CAN_TRANSITION_BETWEEN_SWIM_AND_FLY: case Opcode::SMSG_MOVE_SET_COLLISION_HGT: - case Opcode::SMSG_MOVE_SET_FLIGHT: - case Opcode::SMSG_MOVE_UNSET_FLIGHT: packet.setReadPos(packet.getSize()); break; + case Opcode::SMSG_MOVE_SET_FLIGHT: + handleForceMoveFlagChange(packet, "SET_FLIGHT", Opcode::CMSG_MOVE_FLIGHT_ACK, + static_cast(MovementFlags::FLYING), true); + break; + case Opcode::SMSG_MOVE_UNSET_FLIGHT: + handleForceMoveFlagChange(packet, "UNSET_FLIGHT", Opcode::CMSG_MOVE_FLIGHT_ACK, + static_cast(MovementFlags::FLYING), false); + break; default: // In pre-world states we need full visibility (char create/login handshakes).