From c72186fd11078d9664e0e930d30021b2afc668ce Mon Sep 17 00:00:00 2001 From: Kelsi Date: Tue, 10 Mar 2026 11:36:06 -0700 Subject: [PATCH] net: ack SMSG_MOVE_GRAVITY_DISABLE/ENABLE and fix fall-through bug These opcodes were inadvertently falling through to the LAND_WALK handler (same case label), causing incorrect CMSG_MOVE_WATER_WALK_ACK acks to be sent for gravity changes. Split into dedicated cases that send CMSG_MOVE_GRAVITY_DISABLE_ACK and CMSG_MOVE_GRAVITY_ENABLE_ACK respectively, as required by the server protocol. --- src/game/game_handler.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/game/game_handler.cpp b/src/game/game_handler.cpp index 08d08f2d..f1fe799a 100644 --- a/src/game/game_handler.cpp +++ b/src/game/game_handler.cpp @@ -5534,7 +5534,11 @@ void GameHandler::handlePacket(network::Packet& packet) { // ---- Player movement flag changes (server-pushed) ---- case Opcode::SMSG_MOVE_GRAVITY_DISABLE: + handleForceMoveFlagChange(packet, "GRAVITY_DISABLE", Opcode::CMSG_MOVE_GRAVITY_DISABLE_ACK, 0, true); + break; case Opcode::SMSG_MOVE_GRAVITY_ENABLE: + handleForceMoveFlagChange(packet, "GRAVITY_ENABLE", Opcode::CMSG_MOVE_GRAVITY_ENABLE_ACK, 0, true); + break; case Opcode::SMSG_MOVE_LAND_WALK: handleForceMoveFlagChange(packet, "LAND_WALK", Opcode::CMSG_MOVE_WATER_WALK_ACK, 0, false); break;