mirror of
https://github.com/osukey/osukey.git
synced 2025-08-05 15:44:04 +09:00
Ensure GameplayClockContainer
's FramedClock
is always non-null
This commit is contained in:
@ -48,7 +48,7 @@ namespace osu.Game.Screens.Play
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// The final clock which is exposed to gameplay components.
|
/// The final clock which is exposed to gameplay components.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
protected IFrameBasedClock FramedClock { get; private set; } = null!;
|
protected IFrameBasedClock FramedClock { get; private set; }
|
||||||
|
|
||||||
private readonly BindableBool isPaused = new BindableBool(true);
|
private readonly BindableBool isPaused = new BindableBool(true);
|
||||||
|
|
||||||
@ -69,6 +69,9 @@ namespace osu.Game.Screens.Play
|
|||||||
|
|
||||||
decoupledClock = new DecoupleableInterpolatingFramedClock { IsCoupled = false };
|
decoupledClock = new DecoupleableInterpolatingFramedClock { IsCoupled = false };
|
||||||
IsPaused.BindValueChanged(OnIsPausedChanged);
|
IsPaused.BindValueChanged(OnIsPausedChanged);
|
||||||
|
|
||||||
|
// this will be replaced during load, but non-null for tests which don't add this component to the hierarchy.
|
||||||
|
FramedClock = new FramedClock();
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override IReadOnlyDependencyContainer CreateChildDependencies(IReadOnlyDependencyContainer parent)
|
protected override IReadOnlyDependencyContainer CreateChildDependencies(IReadOnlyDependencyContainer parent)
|
||||||
|
Reference in New Issue
Block a user