Poll for the initial controller state when using DirectInput

This fixes getting a deflected axis as the first buffered input reading on a generic USB controller (G-Shark GS-GP702)
This commit is contained in:
Sam Lantinga
2024-03-20 10:45:11 -07:00
parent 4a7e3beeb9
commit 70b0d33106
2 changed files with 10 additions and 1 deletions

View File

@@ -76,6 +76,7 @@ struct joystick_hwdata
LPDIRECTINPUTDEVICE8 InputDevice;
DIDEVCAPS Capabilities;
SDL_bool buffered;
SDL_bool first_update;
input_t Inputs[MAX_INPUTS];
int NumInputs;
int NumSliders;