XInputGetState is returning ERROR_DEVICE_NOT_CONNECTED (1167) despite the following:
My Logitech F310 controller is plugged in
The controller is set to XInput Mode
The XInput 1.4 DLL is confirmed loaded
I have a valid function pointer to the XInputGetState function in the DLL (it's not the stub)
Yet when the function call is made I get a return value of 1167 back! The controller shows up in Windows and even works to launch things like Steam's Big Picture mode. This used to work!
I'm on Day 23 of Handmade Hero. I've downloaded the source code and Casey's works but I have no idea why. I have diff'd the source code with mine to no end but I don't see what I'm doing wrong as far as the controller related code is concerned.
Does anyone have any ideas on what could be going on here? I'm at a loss. There has to be a bug somewhere.
Here are my project files in case a kind soul wants to review.
My Project Files