mirror of
https://github.com/ppy/osu.git
synced 2025-02-21 03:43:21 +08:00
Merge branch 'add-pp-playtime' of https://github.com/stanriders/osu into add-pp-playtime
This commit is contained in:
commit
119c828962
@ -38,9 +38,9 @@ namespace osu.Game.Overlays.Profile.Header.Components
|
||||
UserStatistics.BindValueChanged(updateTime, true);
|
||||
}
|
||||
|
||||
private void updateTime(ValueChangedEvent<UserStatistics?> user)
|
||||
private void updateTime(ValueChangedEvent<UserStatistics?> statistics)
|
||||
{
|
||||
int? playTime = user.NewValue?.PlayTime;
|
||||
int? playTime = statistics.NewValue?.PlayTime;
|
||||
TooltipText = (playTime ?? 0) / 3600 + " hours";
|
||||
info.Content = formatTime(playTime);
|
||||
}
|
||||
|
@ -7,7 +7,6 @@ using osu.Framework.Extensions.LocalisationExtensions;
|
||||
using osu.Framework.Graphics;
|
||||
using osu.Framework.Graphics.Containers;
|
||||
using osu.Framework.Input.Events;
|
||||
using osu.Framework.Localisation;
|
||||
using osu.Game.Online.API;
|
||||
using osu.Game.Online.API.Requests.Responses;
|
||||
using osu.Game.Overlays.Profile.Header.Components;
|
||||
@ -51,7 +50,7 @@ namespace osu.Game.Users
|
||||
{
|
||||
globalRankDisplay.Content = stats.NewValue?.GlobalRank?.ToLocalisableString("\\##,##0") ?? "-";
|
||||
countryRankDisplay.Content = stats.NewValue?.CountryRank?.ToLocalisableString("\\##,##0") ?? "-";
|
||||
ppDisplay.Content = stats.NewValue?.PP?.ToLocalisableString("#,##0") ?? (LocalisableString)"0";
|
||||
ppDisplay.Content = stats.NewValue?.PP?.ToLocalisableString("#,##0") ?? "0";
|
||||
}, true);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user