Skip to content

Replace new combo button icons with ruleset-specifc ones#37848

Open
LiquidPL wants to merge 3 commits into
ppy:masterfrom
LiquidPL:editor-new-combo-icon
Open

Replace new combo button icons with ruleset-specifc ones#37848
LiquidPL wants to merge 3 commits into
ppy:masterfrom
LiquidPL:editor-new-combo-icon

Conversation

@LiquidPL
Copy link
Copy Markdown
Contributor

@LiquidPL LiquidPL commented May 20, 2026

This makes the new combo button use the new icons added in #37804. Instead of having four separate icons per ruleset, the "sparkle" texture is overlaid on top of the appropriate icon.

I'm not sure if I've overdone it with how every ruleset copypastes the same code for the icon (in <ruleset>BlueprintContainer), so that can be scaled down if necessary.

osu taiko catch mania
image image image image

Depends on ppy/osu-resources#425.

This makes the new combo button use the new icons added
in ppy#37804. Instead of having
four separate icons per ruleset, the "sparkle" texture
is overlaid on top of the appropriate icon.

I'm not sure if I've overdone it with how every ruleset copypastes
the same code for the icon (in `<ruleset>BlueprintContainer`), so that
can be scaled down if necessary.
{
Children = new Drawable[]
{
new SpriteIcon
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

was kinda hoping this would be automatic by just taking the first object type icon, haven't looked into how possible that is though.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

will try to check that out

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Might be somewhat complicated without refactoring some of the button code, since to my understanding (using osu as an example) at the top level there's OsuHitObjectComposer, which defines the hitobject buttons, aka the Toolbox section. However it also pulls in the ternary buttons, New combo among them from OsuBlueprintContainer.

By all this I mean that the data flow goes in the other direction, and it would feel awkward to have OsuBlueprintContainer try to pull the first hitobject to get its icon (which it can't right now since HitObjectComposer.CompositionTools is protected). Generally speaking it is confusing to me why is OsuBlueprintContainer, which is generally concerned with object blueprints, also responsible for all those ternary buttons?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Given there's no internal overrides of CreateTernaryButtons and no other usages of MainTernaryStates, I think you should be safe with moving the whole shebang to HitObjectComposer. These classes got a bit confused over the years, and have been tidied up progressively. This stuff was likely just remaining to be migrated across.

Wanna give that a try?

Copy link
Copy Markdown
Contributor Author

@LiquidPL LiquidPL May 22, 2026

Choose a reason for hiding this comment

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

I can try, however my concern is that since CreateTernaryButtons depends on SelectionHandler which will take more effort to move out since it's defined on the base BlueprintContainer.

I figure I would need to move SelectionHandler up to HitObjectComposer as well, however I'd need to figure out a similar thing for the skin editor as well.

Either way it's probably best to merge this first and deal with said refactor in a future PR.

@peppy peppy self-requested a review May 22, 2026 08:23
@peppy peppy moved this from Inbox to Pending Review in osu! team task tracker May 22, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: Pending Review

Development

Successfully merging this pull request may close these issues.

[Editor] The icon for "New combo" is gone

2 participants