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

Fix mania notes disappearing on seek to their end time #30755

Merged
merged 1 commit into from
Nov 20, 2024

Conversation

bdach
Copy link
Collaborator

@bdach bdach commented Nov 18, 2024

RFC. Would close #30639.

Not too sold on this myself, but it appears to work well enough for a hack.

Options I also considered but didn't end up going through with:

  • applying this sort of delay universally to ManiaHitObject (smelled of twisting gameplay code to editor needs)
  • mutating the replay used internally by DrawableEditorRulesetWrapper to press keys 1ms late instead (no easy entry point to do this, would need to create yet another virtual on Ruleset rather than leveraging existing structures, even though this change ended up doing two levels of virtuals)

@@ -82,6 +85,9 @@ public ManiaPlayfield(List<StageDefinition> stageDefinitions)
}
}

[Pure]
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This annotation is supposed to assuage doubts that may pop up from the "virtual call in ctor" hint-level inspections resulting from this change.

Comment on lines +138 to +145
var action = columnStartAction;
columnStartAction++;
var column = CreateColumn(firstColumnIndex + i, isSpecial).With(c =>
{
RelativeSizeAxes = Axes.Both,
Width = 1,
Action = { Value = columnStartAction++ }
};
c.RelativeSizeAxes = Axes.Both;
c.Width = 1;
c.Action.Value = action;
});
Copy link
Collaborator Author

@bdach bdach Nov 18, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm only sorta confident the columnStartAction changes here are correct. Remember, friends don't let friends use postfix increment in complex expressions. (Ideally ever.)

The rearranging is required because you can't do stuff to ref params from inside a closure.

@bdach bdach force-pushed the fix-mania-notes-disappearing branch from a898da3 to 15a8cfe Compare November 18, 2024 13:37
Copy link
Contributor

@smoogipoo smoogipoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably what I would've done too.

@smoogipoo smoogipoo merged commit b1389ed into ppy:master Nov 20, 2024
9 of 10 checks passed
@bdach bdach deleted the fix-mania-notes-disappearing branch November 20, 2024 09:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

osu!mania notes shouldn't disappear in the editor when seeking to their hit time
2 participants