osu icon indicating copy to clipboard operation
osu copied to clipboard

Add ability to cycle between control point types

Open kongehund opened this issue 1 year ago • 1 comments

This PR adds the ability to change a control point's path type by shift-clicking. When doing so, the control point will cycle between relevant curve types. Specifically:

  • Will only change to perfect curve if the segment has less than 2 inherited points
  • Will only change to inherited if it's not the first point in the slider, and it doesn't break an earlier perfect curve
  • Will only change to B-Spline if the result looks different from Bezier (5 inherited points or more)

This feature makes it faster to change path types, and brings in more familiarity from the osu!standard editor, which has ctrl+click to change a control point to a red anchor. Since ctrl+click is used for selection, shift is used instead.

https://github.com/ppy/osu/assets/63306696/67ed5663-f4dc-4147-a87a-1c733b1d7db2

kongehund avatar Feb 04 '24 23:02 kongehund

Even if we wanted this (which is not a given even if I see some support), it cannot be on shift, because this happens:

https://github.com/ppy/osu/assets/20418176/d26509e5-3feb-4bf9-b0ef-7d57e26488d1

Depending on timing of the shift press the behaviour changes.

  • If you press shift before clicking the slider node changes type and cannot move
  • If you press shift after clicking the slider node begins moving and the shift press makes it snap to the grid

which is not acceptable UX (see also: https://github.com/ppy/osu/pull/25953#issuecomment-2144740349).

bdach avatar Jun 06 '24 12:06 bdach