diff --git a/src/input_common/udp/client.cpp b/src/input_common/udp/client.cpp index 40eed14c4..a5343384c 100644 --- a/src/input_common/udp/client.cpp +++ b/src/input_common/udp/client.cpp @@ -157,8 +157,11 @@ void Client::OnPadData(Response::PadData data) { return; } packet_sequence = data.packet_counter; - Math::Vec3f accel = Math::MakeVec(data.accel.x, data.accel.y, data.accel.z); - Math::Vec3f gyro = Math::MakeVec(data.gyro.pitch, data.gyro.yaw, data.gyro.roll); + // Due to differences between the 3ds and cemuhookudp motion directions, we need to invert + // accel.x and accel.z and also invert pitch and yaw. See + // https://github.com/citra-emu/citra/pull/4049 for more details on gyro/accel + Math::Vec3f accel = Math::MakeVec(-data.accel.x, data.accel.y, -data.accel.z); + Math::Vec3f gyro = Math::MakeVec(-data.gyro.pitch, -data.gyro.yaw, data.gyro.roll); { std::lock_guard guard(status->update_mutex);