-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Fix oversight in osu! pause input handling #29500
Merged
bdach
merged 5 commits into
ppy:master
from
frenzibyte:fix-pausing-for-the-millionth-time
Aug 27, 2024
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
9e962ce
Add failing test case
frenzibyte 62dec1c
Fix oversight in input blocking from osu! gameplay resume
frenzibyte 86d0079
Rewrite the fix to look less hacky and direct to the point
frenzibyte 2a49167
Remove flac whatever
frenzibyte 2ecf5ec
Add further test coverage
frenzibyte File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
Oops, something went wrong.
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.
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.
My initial reading of this was "doesn't this mean that if you paused with
LeftButton
held on a slider, and then want to resume holding by clicking the resume cursor indicator withRightButton
, the nextRightButton
input will get blocked still?" But in testing that... does not appear to be the case for whatever reason? Maybe that has something to do with that entire key up/down syncing/not syncing crap or whatever. Not sure. Any commentary to offer on that?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.
I...think I would want to stick to just block next frame only in that case.
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.
I mean I'd also be fine with "if either left or right button is pressed on the ruleset, don't block the new input" or something.
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.
Actually no, the next
RightButton
will not be blocked, what will be blocked is the point at which the user presses theRightButton
on the orange cursor.The point of adding this conditional is to make sure that we're not blocking next press unless we know for a fact that the next press will be generated within this same frame (generated by the user pressing on the orange cursor and triggering a press on gameplay due to that press).
If that sounds bad then I'll just make it block for one frame no questions asked.
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.
Uhhh... can we just not block either gameplay action if either gameplay action was already pressed before break?
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.
I don't get this. Does this mean a slider will/"should" start tracking immediately if you start holding a new button before unpausing? Because that sounds wrong to me, ignoring whatever stable may be doing.
Like, as far as I understand what we want is very simple on paper:
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.
I think that for sliders specifically, if you're holding a slider with left key, pause, and then want to unpause and continue holding the slider with right key, the input should not get dropped, no? Dropping that input just seems anti-user, they'd have to remember which key they paused with before.
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.
Maybe it sounds anti-user, but allowing it leads to concerns of using pause buffering as an abuse vector. Also it feels weird that holds are seen but new presses aren't?
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.
@peppy There's a difference between what you said here and what I'm conveying here. If the user held a key, then unpaused with another key, only the key that was used for unpausing will be seen by gameplay, the other will not be.
As far as I'm aware, you can change keys while holding a slider, so there's no issue here?
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.
The key explicitly used to trigger the unpause can be seen as a hold only, i guess, sure. It's still a bit haphazard (that it only happens for hold not click) but sure.