1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-12 21:02:54 +08:00

Get recent count from api instead

This commit is contained in:
Joseph Madamba 2021-04-24 09:26:43 -07:00
parent d6f2e0defb
commit 59cb5f4679
2 changed files with 6 additions and 3 deletions

View File

@ -39,6 +39,9 @@ namespace osu.Game.Overlays.Profile.Sections.Ranks
case ScoreType.Firsts:
return user.ScoresFirstCount;
case ScoreType.Recent:
return user.ScoresRecentCount;
default:
return 0;
}
@ -50,9 +53,6 @@ namespace osu.Game.Overlays.Profile.Sections.Ranks
drawableItemIndex = 0;
base.OnItemsReceived(items);
if (type == ScoreType.Recent)
SetCount(items.Count);
}
protected override APIRequest<List<APILegacyScoreInfo>> CreateRequest() =>

View File

@ -147,6 +147,9 @@ namespace osu.Game.Users
[JsonProperty(@"scores_first_count")]
public int ScoresFirstCount;
[JsonProperty(@"scores_recent_count")]
public int ScoresRecentCount;
[JsonProperty(@"beatmap_playcounts_count")]
public int BeatmapPlaycountsCount;