-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Controller device reservation / preference. #16647
Controller device reservation / preference. #16647
Conversation
0f0b157
to
68981e4
Compare
Please follow the common capitalization standard with menu item labels. |
How does a reservation interact with 2 identical pads? E.g. a pair of xbox controllers? Does it just allocate the first one it sees to the first open reservation? |
Also, not sure if could consider also this issue ? |
@gouchi I think this PR can address the example in that issue by assigning the SNES controllers to players 1-4, or assigning the joystick to a non-playable player for that core (like player 5) |
0b8994c
to
a7d2b6e
Compare
I ran a test with identical pads and the result is not quite right, I'll make an update (maybe tomorrow) |
For each player, 2 new options are added: - a reservation type (no reservation, preferred, reserved) - a reserved device name When handling port - player assignments, reserved devices will be assigned to the respective player port. If reservation type is "reserved", no other device can take that port automatically. Reservation config option and matching function lifted from: PatrickStankard libretro#16269 Test joypad driver was extended for more tests. Co-authored-by: Patrick Stankard <me@patrickstankard.com>
4f3a8c6
to
efb45c1
Compare
Update uploaded, with a new test scenario. Reserving multiple entries for the same controller type should work now. About #6707, I am not quite sure. There is a lot of discussion under that ticket, some cases mentioned can be solved now, others I think should be already covered by earlier PRs like #12534 . |
efb45c1
to
ce9d94e
Compare
Description
For each player, 2 new options are added:
When a new device is added via autoconfig, it will be added to the first free player. Reserved devices will be assigned to the reserved player slot. If reservation type is "reserved", no other device can take that player slot automatically. If reservation type is "preferred", other device can be mapped, but as soon as the preferred device appears, it will be mapped there.
Some notes:
Reservation config option and matching function lifted from PatrickStankard: #16269
Test joypad driver was extended for more tests, see the .cfg for a scenario (last file in diff).
(edit: re-worded a bit. "port" is the identifier used inside the input/joypad driver, I used "slot" for the player <-> port assignment)
Related Issues
#12924
#12200
Related Pull Requests
#16269
Reviewers
@PatrickStankard