1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-25 06:23:21 +08:00

Use stored difficulty to reduce flickering

This commit is contained in:
Dan Balasescu 2024-10-17 20:39:24 +09:00
parent 2ce1475303
commit 0473f0b60a
No known key found for this signature in database

View File

@ -21,7 +21,6 @@ using osu.Game.Localisation;
using osu.Game.Localisation.SkinComponents;
using osu.Game.Resources.Localisation.Web;
using osu.Game.Rulesets;
using osu.Game.Rulesets.Difficulty;
using osu.Game.Rulesets.Mods;
using osu.Game.Utils;
@ -225,9 +224,7 @@ namespace osu.Game.Skinning.Components
return (starDifficulty?.Stars ?? 0).ToLocalisableString(@"F2");
case BeatmapAttribute.MaxPP:
return difficultyBindable?.Value?.PerformanceAttributes is PerformanceAttributes attributes
? attributes.Total.ToLocalisableString(@"F2")
: @"...";
return (starDifficulty?.PerformanceAttributes?.Total ?? 0).ToLocalisableString(@"F2");
default:
throw new ArgumentOutOfRangeException();