-
Notifications
You must be signed in to change notification settings - Fork 637
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
Feature: Auto-Assign Controllers #706
Open
uncavo-hdmi
wants to merge
29
commits into
Ryubing:master
Choose a base branch
from
uncavo-hdmi:auto-assign-controller
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
+500
−11
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…nd update related components
…ve controller refresh logic
…better controller management
…nditionally update configuration
…tionality; update gamepad connection handling to load configuration while in Input settings.
… order caused the configuration to load incorrectly.
…pad connection changes; improve controller assignment logic and ensure proper LED color settings
…ion methods; changed some settings for LED color
… color handling in the new function.
…in settings (no easy way to constantly update it)
…ConfiguredController function.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Feature: Auto-Assign Controllers
This PR introduces an auto-assigning controllers feature to Ryujinx, enhancing user experience by automatically detecting and assigning connected controllers to player slots. This streamlines the setup process, allowing users to start playing without manual configuration.
Changes & Enhancements:
Input
settings page now automatically refreshes when a controller is connected.Input
settings page to enable or disable the feature.Implementation Details:
Assignment Logic: Controllers are assigned sequentially, starting from Player 1.
Enable feature: The feature can be toggled on or off using a checkbox in the Input settings page. By default, it is disabled.
No Conflicts: This feature does not interfere with manual controller assignments, profile selection logic, or controller binding settings. It only modifies the configuration file when new controllers are connected.
No configuration loss: When controllers are disconnected, no controller configuration will be erased (unless manually deassigned using "Disabled").
Initial controller config: Since a configuration is necessary to successfully use a controller, this feature provides default controller configurations:
Ignore Applet: When the feature is enabled, it automatically enables the
Ignore Applet
setting and disables the checkbox, preventing it from being toggled on or off. This ensures seamless controller detection without applet interference.Why add this feature?
Manually assigning controllers can be cumbersome, especially in scenarios where users have multiple controllers or frequently connect/disconnect devices. This feature aims to simplify the setup process by automatically assigning controllers, saving time and reducing the hassle of manual configuration.
Known issues
File Organization
AutoAssignController.cs
(main class) andControllerAssignmentManager.cs
(helper class) are placed inRyujinx/Input
.Issues with Joy-Con Configurations
During testing to create default configurations for each controller, I encountered several issues with the Joy-Con controllers:
Controller Reassignment Bug (Unrelated to This PR)
This issue was encountered while testing, but I confirmed that it also occurs in the main Ryujinx repository. This is not caused by changes in this PR, but I am documenting it here in case anyone else encounters it (the same applies to the next issue).
Steps to Reproduce:
Expected Behavior: The controller should function normally after being reassigned.
Actual Behavior: The controller stops working after switching from “Disabled” back to an assigned controller.
Additional note: It appears to happen only when switching from 'Disabled' back to a controller
Crash on Game Relaunch (Unrelated to This PR)
Steps to Reproduce:
Expected Behavior: The game should start normally.
Actual Behavior: The emulator crashes on the "Loading" screen when attempting to restart the game.