mirror of
https://github.com/osukey/osukey.git
synced 2025-05-25 23:47:30 +09:00
Fix clock assigning during KeyCounterCollection creation
This commit is contained in:
parent
0632c59e60
commit
1d9bf42082
@ -68,7 +68,7 @@ namespace osu.Game.Screens.Play
|
|||||||
Direction = FillDirection.Vertical,
|
Direction = FillDirection.Vertical,
|
||||||
Children = new Drawable[]
|
Children = new Drawable[]
|
||||||
{
|
{
|
||||||
KeyCounter = CreateKeyCounter(),
|
KeyCounter = CreateKeyCounter(offsetClock),
|
||||||
HoldToQuit = CreateQuitButton(),
|
HoldToQuit = CreateQuitButton(),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -79,7 +79,7 @@ namespace osu.Game.Screens.Play
|
|||||||
BindRulesetContainer(rulesetContainer);
|
BindRulesetContainer(rulesetContainer);
|
||||||
|
|
||||||
Progress.Objects = rulesetContainer.Objects;
|
Progress.Objects = rulesetContainer.Objects;
|
||||||
Progress.AudioClock = KeyCounter.AudioClock = offsetClock;
|
Progress.AudioClock = offsetClock;
|
||||||
Progress.AllowSeeking = rulesetContainer.HasReplayLoaded;
|
Progress.AllowSeeking = rulesetContainer.HasReplayLoaded;
|
||||||
Progress.OnSeek = pos => adjustableClock.Seek(pos);
|
Progress.OnSeek = pos => adjustableClock.Seek(pos);
|
||||||
|
|
||||||
@ -193,12 +193,13 @@ namespace osu.Game.Screens.Play
|
|||||||
Margin = new MarginPadding { Top = 20 }
|
Margin = new MarginPadding { Top = 20 }
|
||||||
};
|
};
|
||||||
|
|
||||||
protected virtual KeyCounterCollection CreateKeyCounter() => new KeyCounterCollection
|
protected virtual KeyCounterCollection CreateKeyCounter(IClock offsetClock) => new KeyCounterCollection
|
||||||
{
|
{
|
||||||
FadeTime = 50,
|
FadeTime = 50,
|
||||||
Anchor = Anchor.BottomRight,
|
Anchor = Anchor.BottomRight,
|
||||||
Origin = Anchor.BottomRight,
|
Origin = Anchor.BottomRight,
|
||||||
Margin = new MarginPadding(10),
|
Margin = new MarginPadding(10),
|
||||||
|
AudioClock = offsetClock
|
||||||
};
|
};
|
||||||
|
|
||||||
protected virtual ScoreCounter CreateScoreCounter() => new ScoreCounter(6)
|
protected virtual ScoreCounter CreateScoreCounter() => new ScoreCounter(6)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user