1
0
mirror of https://github.com/ppy/osu.git synced 2025-03-15 16:27:21 +08:00

Revert highlighting recent scores

This commit is contained in:
dekrain 2022-02-19 21:23:35 +01:00
parent 31b7ce053d
commit 262751a98a
No known key found for this signature in database
GPG Key ID: E20077A4AB510334

View File

@ -390,28 +390,13 @@ namespace osu.Game.Online.Leaderboards
private class DateLabel : DrawableDate
{
public static readonly Colour4 COLOUR_SATURATED = Colour4.Lime;
public static readonly Colour4 COLOUR_UNSATURATED = Colour4.White;
public DateLabel(DateTimeOffset date)
: base(date)
{
Font = OsuFont.GetFont(size: 17, weight: FontWeight.Bold, italics: true);
}
protected override string Format()
{
var now = DateTime.Now;
var difference = now - Date;
const double seconds_to_blank = 60 * 45;
const double tense_factor = 2.325;
double tf = Math.Pow(difference.TotalSeconds / seconds_to_blank, tense_factor);
Colour = Interpolation.ValueAt(tf, COLOUR_SATURATED, COLOUR_UNSATURATED, 0, 1);
return ScoreboardTimeUtils.FormatDate(Date, TimeSpan.FromSeconds(30));
}
protected override string Format() => ScoreboardTimeUtils.FormatDate(Date, TimeSpan.FromSeconds(30));
}
public class LeaderboardScoreStatistic