mirror of
https://github.com/ppy/osu.git
synced 2025-02-23 12:13:30 +08:00
Hook up score totals display to daily challenge screen
This commit is contained in:
parent
1ad0b31217
commit
2e37f3b5de
@ -59,6 +59,7 @@ namespace osu.Game.Screens.OnlinePlay.DailyChallenge
|
|||||||
private IDisposable? userModsSelectOverlayRegistration;
|
private IDisposable? userModsSelectOverlayRegistration;
|
||||||
|
|
||||||
private DailyChallengeScoreBreakdown breakdown = null!;
|
private DailyChallengeScoreBreakdown breakdown = null!;
|
||||||
|
private DailyChallengeTotalsDisplay totals = null!;
|
||||||
private DailyChallengeEventFeed feed = null!;
|
private DailyChallengeEventFeed feed = null!;
|
||||||
|
|
||||||
[Cached]
|
[Cached]
|
||||||
@ -211,6 +212,7 @@ namespace osu.Game.Screens.OnlinePlay.DailyChallenge
|
|||||||
{
|
{
|
||||||
new DailyChallengeTimeRemainingRing(),
|
new DailyChallengeTimeRemainingRing(),
|
||||||
breakdown = new DailyChallengeScoreBreakdown(),
|
breakdown = new DailyChallengeScoreBreakdown(),
|
||||||
|
totals = new DailyChallengeTotalsDisplay(),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -351,6 +353,7 @@ namespace osu.Game.Screens.OnlinePlay.DailyChallenge
|
|||||||
Schedule(() =>
|
Schedule(() =>
|
||||||
{
|
{
|
||||||
breakdown.AddNewScore(ev);
|
breakdown.AddNewScore(ev);
|
||||||
|
totals.AddNewScore(ev);
|
||||||
feed.AddNewScore(ev);
|
feed.AddNewScore(ev);
|
||||||
|
|
||||||
if (e.NewRank <= 50)
|
if (e.NewRank <= 50)
|
||||||
@ -421,7 +424,11 @@ namespace osu.Game.Screens.OnlinePlay.DailyChallenge
|
|||||||
var itemStats = stats.SingleOrDefault(item => item.PlaylistItemID == playlistItem.ID);
|
var itemStats = stats.SingleOrDefault(item => item.PlaylistItemID == playlistItem.ID);
|
||||||
if (itemStats == null) return;
|
if (itemStats == null) return;
|
||||||
|
|
||||||
Schedule(() => breakdown.SetInitialCounts(itemStats.TotalScoreDistribution));
|
Schedule(() =>
|
||||||
|
{
|
||||||
|
breakdown.SetInitialCounts(itemStats.TotalScoreDistribution);
|
||||||
|
totals.SetInitialCounts(itemStats.TotalScoreDistribution.Sum(c => c), itemStats.TotalPlaylistScore);
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
beatmapAvailabilityTracker.SelectedItem.Value = playlistItem;
|
beatmapAvailabilityTracker.SelectedItem.Value = playlistItem;
|
||||||
|
Loading…
Reference in New Issue
Block a user