mirror of
https://github.com/ppy/osu.git
synced 2025-01-12 18:23:04 +08:00
Get recent count from api instead
This commit is contained in:
parent
d6f2e0defb
commit
59cb5f4679
@ -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() =>
|
||||
|
@ -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;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user