1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-06 12:17:46 +08:00

Add full xmldoc

This commit is contained in:
Dean Herbert 2021-10-02 02:28:35 +09:00
parent 32afd3f426
commit 7e009f6168

View File

@ -12,6 +12,9 @@ using osu.Game.Rulesets.Mods;
namespace osu.Game.Screens.Play namespace osu.Game.Screens.Play
{ {
/// <summary>
/// The state of an active gameplay session, generally constructed and exposed by <see cref="Player"/>.
/// </summary>
public class GameplayState public class GameplayState
{ {
/// <summary> /// <summary>
@ -19,10 +22,23 @@ namespace osu.Game.Screens.Play
/// </summary> /// </summary>
public readonly IBeatmap Beatmap; public readonly IBeatmap Beatmap;
/// <summary>
/// The ruleset used in gameplay.
/// </summary>
public readonly Ruleset Ruleset; public readonly Ruleset Ruleset;
/// <summary>
/// The mods applied to the gameplay.
/// </summary>
public IReadOnlyList<Mod> Mods; public IReadOnlyList<Mod> Mods;
/// <summary>
/// A bindable tracking the last judgement result applied to any hit object.
/// </summary>
public IBindable<JudgementResult> LastJudgementResult => lastJudgementResult;
private readonly Bindable<JudgementResult> lastJudgementResult = new Bindable<JudgementResult>();
public GameplayState(IBeatmap beatmap, Ruleset ruleset, IReadOnlyList<Mod> mods) public GameplayState(IBeatmap beatmap, Ruleset ruleset, IReadOnlyList<Mod> mods)
{ {
Beatmap = beatmap; Beatmap = beatmap;
@ -30,10 +46,10 @@ namespace osu.Game.Screens.Play
Mods = mods; Mods = mods;
} }
private readonly Bindable<JudgementResult> lastJudgementResult = new Bindable<JudgementResult>(); /// <summary>
/// Applies the score change of a <see cref="JudgementResult"/> to this <see cref="GameplayState"/>.
public IBindable<JudgementResult> LastJudgementResult => lastJudgementResult; /// </summary>
/// <param name="result">The <see cref="JudgementResult"/> to apply.</param>
public void ApplyResult(JudgementResult result) => lastJudgementResult.Value = result; public void ApplyResult(JudgementResult result) => lastJudgementResult.Value = result;
} }
} }