1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-06 07:42:55 +08:00

Align inspector info more to how it is shown for osu

This commit is contained in:
Darius Wattimena 2024-11-19 19:54:12 +01:00
parent 111f029ead
commit a8e14b6625

View File

@ -21,21 +21,18 @@ namespace osu.Game.Rulesets.Catch.Edit
HitObject? precedingObject = EditorBeatmap.HitObjects.LastOrDefault(ho => ho.GetEndTime() < firstSelectedHitObject.StartTime);
HitObject? nextObject = EditorBeatmap.HitObjects.FirstOrDefault(ho => ho.StartTime > lastSelectedHitObject.GetEndTime());
if (precedingObject != null || nextObject != null)
{
AddHeader("Snapping");
}
if (precedingObject != null)
{
double previousSnap = snapProvider.ReadCurrentDistanceSnap(precedingObject, firstSelectedHitObject);
AddValue($"Previous: {previousSnap:#,0.##}x");
AddHeader("To previous");
AddValue($"{previousSnap:#,0.##}x");
}
if (nextObject != null)
{
double nextSnap = snapProvider.ReadCurrentDistanceSnap(lastSelectedHitObject, nextObject);
AddValue($"Next: {nextSnap:#,0.##}x");
AddHeader("To next");
AddValue($"{nextSnap:#,0.##}x");
}
}
}