1
0
mirror of https://github.com/ppy/osu.git synced 2024-09-22 10:07:36 +08:00

Use GetEndTime() instead of StartTime

Companion to
246479bf34
This commit is contained in:
Salman Ahmed 2022-05-06 18:51:34 +03:00
parent 112496204d
commit d78f1d158d

View File

@ -131,7 +131,7 @@ namespace osu.Game.Screens.Edit.Compose.Components
if (editorClock == null)
return;
float distanceForCurrentTime = snapProvider.DurationToDistance(referenceObject, editorClock.CurrentTime - referenceObject.StartTime);
float distanceForCurrentTime = snapProvider.DurationToDistance(referenceObject, editorClock.CurrentTime - referenceObject.GetEndTime());
float timeBasedAlpha = Math.Clamp(1 - Math.Abs(distanceForCurrentTime - Size.X / 2) / 30, 0, 1);
Colour = baseColour.Opacity(Math.Max(baseColour.A, timeBasedAlpha));