-
-
Notifications
You must be signed in to change notification settings - Fork 21.1k
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
Revert #55978 "Fixed event spam when using the Nintendo Switch controller" #56028
Revert #55978 "Fixed event spam when using the Nintendo Switch controller" #56028
Conversation
As I understand it, this needs to be made optional with a project setting so that users who need more precision (steering wheels/HOTAS) can opt in. Otherwise, this filter should remain enabled by default as having only 128 levels of pressure isn't an issue for analog sticks or analog keyboards. Most indie games don't need (good) steering wheel or HOTAS support, but good gamepad support is important to most games. |
CC @slouken |
Yeah I reviewed and merged this a bit fast (and it's included in 3.4.1 which I'm about to release - but I think the issue it reintroduces is less problematic than the bug it's fixing, so it's not too bad IMO. We can improve this in 3.4.2.). I agree that this filter seems mostly relevant for joysticks at rest, and thus a minimal deadzone (which can be configurable, but should have a good default value) makes sense. And then another option for sensitivity can be useful if there's a need indeed, though it seems the main issue is really the idle point. |
A deadzone would also solve the issue with "not pressed" events being continually sent, but note that the problem occurs anytime the joystick is outside the deadzone but less than 0.5. The deadzone also varies significantly between controllers and even individual controllers, so if someone is testing with a PS4 controller and creates a tight deadzone (e.g. 4000) based on observed values, then this issue will crop up again. Maybe it makes sense for the input logic to be changed so if you have pressed events, they override not-pressed events? |
Exactly. The only problem #55978 is solving is #43674 (noisy events generated by sensitive joysticks), which IMO is less significant than #42876. Note: #55978 would make #42876 worse, because now only motions greater than 0.05 (previously it was 0.01) would be detected.
Note: #47599 fixes #45628 i.e. the problem with not pressed events being sent. |
IINM (and I should have spotted that on first review before merging), this actually limits sensitivity to 20 levels (5% increments) per direction, which seems quite extreme. The previous filter or 0.01 was more reasonable IMO. I agree with reverting this PR for now, but I guess we should keep track of the discussion and proposed solution(s) in a new issue (or PR directly)? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved as it fixes a regression, albeit it reintroduces a bug that will need a different fix.
Thanks! |
I'll open a proposal where it can be discussed in a central location as the issues are now spread across multiple issues and PRs. |
I've created godotengine/godot-proposals#3709. |
#55978 will reintroduce #42876. As discussed in #43674, instead of imposing a fixed limit on the sensitivity of the joystick, we need a user configurable project settings with Godot defaults for both the joystick sensitivity and the joystick deadzone.