Fix case of zero rate calculating a zero true gameplay rate

This commit is contained in:
Dean Herbert 2022-09-07 19:23:44 +09:00
parent 1be3b74ff3
commit e6b449fe0b

View File

@ -14,7 +14,7 @@ namespace osu.Game.Screens.Play
public static double GetTrueGameplayRate(this IGameplayClock clock)
{
// To handle rewind, we still want to maintain the same direction as the underlying clock.
double rate = Math.Sign(clock.Rate);
double rate = clock.Rate == 0 ? 1 : Math.Sign(clock.Rate);
return rate
* clock.GameplayAdjustments.AggregateFrequency.Value