Initial conversion of taiko to use ScrollingPlayfield.

This commit is contained in:
smoogipooo
2017-08-08 16:01:18 +09:00
parent 8585561557
commit a95ee7494f
11 changed files with 41 additions and 123 deletions

View File

@ -118,7 +118,6 @@ namespace osu.Game.Rulesets.Taiko.Objects.Drawables
});
MainPiece.Add(symbol = new SwellSymbolPiece());
}
[BackgroundDependencyLoader]
@ -189,20 +188,22 @@ namespace osu.Game.Rulesets.Taiko.Objects.Drawables
Expire();
}
protected override void UpdateScrollPosition(double time)
protected override void Update()
{
// Make the swell stop at the hit target
double t = Math.Min(HitObject.StartTime, time);
base.Update();
// Make the swell stop at the hit target
X = (float)Math.Max(Time.Current, HitObject.StartTime);
double t = Math.Min(HitObject.StartTime, Time.Current);
if (t == HitObject.StartTime && !hasStarted)
{
OnStart?.Invoke();
hasStarted = true;
}
base.UpdateScrollPosition(t);
}
protected override bool HandleKeyPress(Key key)
{
if (Judgement.Result != HitResult.None)