From 79dd9674fc5a580a10d3005d272a1b94b4aaff4c Mon Sep 17 00:00:00 2001 From: Dean Herbert Date: Tue, 14 Dec 2021 17:41:02 +0900 Subject: [PATCH] Use longer form to read better Using `l.StartTime` reads like a coding issue, even though if you go down the call chain looks to be correct. --- osu.Game/Storyboards/StoryboardSprite.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/osu.Game/Storyboards/StoryboardSprite.cs b/osu.Game/Storyboards/StoryboardSprite.cs index f941cec20c..ebd1a941a8 100644 --- a/osu.Game/Storyboards/StoryboardSprite.cs +++ b/osu.Game/Storyboards/StoryboardSprite.cs @@ -33,8 +33,8 @@ namespace osu.Game.Storyboards foreach (var l in loops) { - if (l.EarliestDisplayedTime != null) - earliestStartTime = Math.Min(earliestStartTime, l.StartTime); + if (l.EarliestDisplayedTime is double loopEarliestDisplayTime) + earliestStartTime = Math.Min(earliestStartTime, l.LoopStartTime + loopEarliestDisplayTime); } if (earliestStartTime < double.MaxValue)