Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Explicitly define gamepad type for console platforms #7660

Merged
merged 1 commit into from
Jan 27, 2025

Conversation

StephenCWills
Copy link
Member

Did I miss any? Should we add one for UWP, even though that also technically runs on Windows?

glebm
glebm previously approved these changes Jan 15, 2025
@StephenCWills
Copy link
Member Author

FWIW, I think UWP only supports XInput and may therefore assume that every controller is an Xbox controller. So even if SDL_GameControllerTypeForIndex() is able to return something other than SDL_CONTROLLER_TYPE_UNKNOWN, I'm not sure if it would be able to differentiate different types of controllers.

Still might be a good idea to test it, though.

@StephenCWills
Copy link
Member Author

StephenCWills commented Jan 26, 2025

I tested the UWP build from 5b66f12 on Windows 10 just now. I checked in Settings > Padmapping and saw that it was using the generic layout so I went ahead and added set(DEVILUTIONX_GAMEPAD_TYPE Xbox). FWIW, I also confirmed that my controller doesn't work unless I switch it over to XInput, but since SDL doesn't recognize the controller type, it's kind of a moot point.

EDIT: I just tested the UWP build from this PR for good measure, and I have confirmed that it is using the Xbox layout.

@AJenbo AJenbo merged commit 7f7924d into diasurgical:master Jan 27, 2025
23 checks passed
@StephenCWills StephenCWills deleted the explicit-gamepad-types branch January 27, 2025 17:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants