2022-12-22 15:01:52 +08:00
|
|
|
// Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the MIT Licence.
|
|
|
|
// See the LICENCE file in the repository root for full licence text.
|
|
|
|
|
|
|
|
using osu.Game.Scoring;
|
|
|
|
using osu.Game.Users;
|
|
|
|
|
2024-02-29 06:13:31 +08:00
|
|
|
namespace osu.Game.Online
|
2022-12-22 15:01:52 +08:00
|
|
|
{
|
|
|
|
/// <summary>
|
|
|
|
/// Contains data about the change in a user's profile statistics after completing a score.
|
|
|
|
/// </summary>
|
2024-02-23 02:50:46 +08:00
|
|
|
public class UserStatisticsUpdate
|
2022-12-22 15:01:52 +08:00
|
|
|
{
|
|
|
|
/// <summary>
|
|
|
|
/// The score set by the user that triggered the update.
|
|
|
|
/// </summary>
|
|
|
|
public ScoreInfo Score { get; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// The user's profile statistics prior to the score being set.
|
|
|
|
/// </summary>
|
|
|
|
public UserStatistics Before { get; }
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
/// The user's profile statistics after the score was set.
|
|
|
|
/// </summary>
|
|
|
|
public UserStatistics After { get; }
|
|
|
|
|
|
|
|
/// <summary>
|
2024-02-23 02:50:46 +08:00
|
|
|
/// Creates a new <see cref="UserStatisticsUpdate"/>.
|
2022-12-22 15:01:52 +08:00
|
|
|
/// </summary>
|
|
|
|
/// <param name="score">The score set by the user that triggered the update.</param>
|
|
|
|
/// <param name="before">The user's profile statistics prior to the score being set.</param>
|
|
|
|
/// <param name="after">The user's profile statistics after the score was set.</param>
|
2024-02-23 02:50:46 +08:00
|
|
|
public UserStatisticsUpdate(ScoreInfo score, UserStatistics before, UserStatistics after)
|
2022-12-22 15:01:52 +08:00
|
|
|
{
|
|
|
|
Score = score;
|
|
|
|
Before = before;
|
|
|
|
After = after;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|