From 1ad41db6c99721946083fd3a214020229818b0cf Mon Sep 17 00:00:00 2001 From: hiker Date: Tue, 15 Mar 2016 00:04:00 +1100 Subject: [PATCH] Fixed reading code which ignored 2 bytes. --- src/network/protocols/controller_events_protocol.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/network/protocols/controller_events_protocol.cpp b/src/network/protocols/controller_events_protocol.cpp index a7613f3ed..66a88188e 100644 --- a/src/network/protocols/controller_events_protocol.cpp +++ b/src/network/protocols/controller_events_protocol.cpp @@ -55,7 +55,6 @@ bool ControllerEventsProtocol::notifyEventAsynchronous(Event* event) uint8_t client_index = -1; while (data.size() >= 9) { - //uint8_t controller_index = ns.gui8(); uint8_t kart_id = data.getUInt8(); if (kart_id >=World::getWorld()->getNumKarts()) { @@ -64,6 +63,8 @@ bool ControllerEventsProtocol::notifyEventAsynchronous(Event* event) continue; } uint8_t serialized_1 = data.getUInt8(); + uint8_t serialized_2 = data.getUInt8(); + uint8_t serialized_3 = data.getUInt8(); PlayerAction action = (PlayerAction)(data.getUInt8()); int action_value = data.getUInt32(); Log::info("ControllerEventsProtocol", "KartID %d action %d value %d",