diff --git a/Windows/DinputDevice.cpp b/Windows/DinputDevice.cpp index a680a9dc8f..4a95ca375f 100644 --- a/Windows/DinputDevice.cpp +++ b/Windows/DinputDevice.cpp @@ -85,6 +85,8 @@ DinputDevice::DinputDevice() { last_lX_ = 0; last_lY_ = 0; last_lZ_ = 0; + last_lRx_ = 0; + last_lRy_ = 0; last_lRz_ = 0; if(FAILED(DirectInput8Create(GetModuleHandle(NULL),DIRECTINPUT_VERSION,IID_IDirectInput8,(void**)&pDI,NULL))) @@ -182,6 +184,8 @@ int DinputDevice::UpdateState(InputState &input_state) { SendNativeAxis(DEVICE_ID_PAD_0, js.lX, last_lX_, JOYSTICK_AXIS_X); SendNativeAxis(DEVICE_ID_PAD_0, js.lY, last_lY_, JOYSTICK_AXIS_Y); SendNativeAxis(DEVICE_ID_PAD_0, js.lZ, last_lZ_, JOYSTICK_AXIS_Z); + SendNativeAxis(DEVICE_ID_PAD_0, js.lRx, last_lRx_, JOYSTICK_AXIS_RX); + SendNativeAxis(DEVICE_ID_PAD_0, js.lRy, last_lRy_, JOYSTICK_AXIS_RY); SendNativeAxis(DEVICE_ID_PAD_0, js.lRz, last_lRz_, JOYSTICK_AXIS_RZ); } diff --git a/Windows/DinputDevice.h b/Windows/DinputDevice.h index 978aff62e6..fe2d5d9aee 100644 --- a/Windows/DinputDevice.h +++ b/Windows/DinputDevice.h @@ -40,5 +40,7 @@ private: short last_lX_; short last_lY_; short last_lZ_; + short last_lRx_; + short last_lRy_; short last_lRz_; };