diff options
author | german <german@thesoftwareartisans.com> | 2021-01-10 18:37:19 +0100 |
---|---|---|
committer | german <german@thesoftwareartisans.com> | 2021-02-04 03:17:08 +0100 |
commit | f30ef987615729f5a3b8eab524ce5680369057e9 (patch) | |
tree | 665cfd2d8191212f80b5d6bdc3bbe6aa39de8385 /src/core/hle/service/hid/controllers/npad.cpp | |
parent | Merge pull request #5863 from ogniK5377/disable-reverb (diff) | |
download | yuzu-f30ef987615729f5a3b8eab524ce5680369057e9.tar yuzu-f30ef987615729f5a3b8eab524ce5680369057e9.tar.gz yuzu-f30ef987615729f5a3b8eab524ce5680369057e9.tar.bz2 yuzu-f30ef987615729f5a3b8eab524ce5680369057e9.tar.lz yuzu-f30ef987615729f5a3b8eab524ce5680369057e9.tar.xz yuzu-f30ef987615729f5a3b8eab524ce5680369057e9.tar.zst yuzu-f30ef987615729f5a3b8eab524ce5680369057e9.zip |
Diffstat (limited to 'src/core/hle/service/hid/controllers/npad.cpp')
-rw-r--r-- | src/core/hle/service/hid/controllers/npad.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/core/hle/service/hid/controllers/npad.cpp b/src/core/hle/service/hid/controllers/npad.cpp index 0c227b135..251db1f84 100644 --- a/src/core/hle/service/hid/controllers/npad.cpp +++ b/src/core/hle/service/hid/controllers/npad.cpp @@ -609,7 +609,9 @@ void Controller_NPad::OnMotionUpdate(const Core::Timing::CoreTiming& core_timing UNREACHABLE(); break; case NPadControllerType::ProController: + full_sixaxis_entry.attribute.raw = 0; if (sixaxis_sensors_enabled && motions[i][0]) { + full_sixaxis_entry.attribute.IsConnected.Assign(1); full_sixaxis_entry.accel = motion_devices[0].accel; full_sixaxis_entry.gyro = motion_devices[0].gyro; full_sixaxis_entry.rotation = motion_devices[0].rotation; @@ -617,7 +619,9 @@ void Controller_NPad::OnMotionUpdate(const Core::Timing::CoreTiming& core_timing } break; case NPadControllerType::Handheld: + handheld_sixaxis_entry.attribute.raw = 0; if (sixaxis_sensors_enabled && motions[i][0]) { + handheld_sixaxis_entry.attribute.IsConnected.Assign(1); handheld_sixaxis_entry.accel = motion_devices[0].accel; handheld_sixaxis_entry.gyro = motion_devices[0].gyro; handheld_sixaxis_entry.rotation = motion_devices[0].rotation; @@ -625,8 +629,11 @@ void Controller_NPad::OnMotionUpdate(const Core::Timing::CoreTiming& core_timing } break; case NPadControllerType::JoyDual: + dual_left_sixaxis_entry.attribute.raw = 0; + dual_right_sixaxis_entry.attribute.raw = 0; if (sixaxis_sensors_enabled && motions[i][0]) { // Set motion for the left joycon + dual_left_sixaxis_entry.attribute.IsConnected.Assign(1); dual_left_sixaxis_entry.accel = motion_devices[0].accel; dual_left_sixaxis_entry.gyro = motion_devices[0].gyro; dual_left_sixaxis_entry.rotation = motion_devices[0].rotation; @@ -634,6 +641,7 @@ void Controller_NPad::OnMotionUpdate(const Core::Timing::CoreTiming& core_timing } if (sixaxis_sensors_enabled && motions[i][1]) { // Set motion for the right joycon + dual_right_sixaxis_entry.attribute.IsConnected.Assign(1); dual_right_sixaxis_entry.accel = motion_devices[1].accel; dual_right_sixaxis_entry.gyro = motion_devices[1].gyro; dual_right_sixaxis_entry.rotation = motion_devices[1].rotation; @@ -641,7 +649,9 @@ void Controller_NPad::OnMotionUpdate(const Core::Timing::CoreTiming& core_timing } break; case NPadControllerType::JoyLeft: + left_sixaxis_entry.attribute.raw = 0; if (sixaxis_sensors_enabled && motions[i][0]) { + left_sixaxis_entry.attribute.IsConnected.Assign(1); left_sixaxis_entry.accel = motion_devices[0].accel; left_sixaxis_entry.gyro = motion_devices[0].gyro; left_sixaxis_entry.rotation = motion_devices[0].rotation; @@ -649,7 +659,9 @@ void Controller_NPad::OnMotionUpdate(const Core::Timing::CoreTiming& core_timing } break; case NPadControllerType::JoyRight: + right_sixaxis_entry.attribute.raw = 0; if (sixaxis_sensors_enabled && motions[i][1]) { + right_sixaxis_entry.attribute.IsConnected.Assign(1); right_sixaxis_entry.accel = motion_devices[1].accel; right_sixaxis_entry.gyro = motion_devices[1].gyro; right_sixaxis_entry.rotation = motion_devices[1].rotation; |