1
0
mirror of https://github.com/ppy/osu.git synced 2024-12-14 15:33:05 +08:00

Add basic slider judgement handling.

This commit is contained in:
Dean Herbert 2016-11-29 21:40:24 +09:00
parent a0503bd13f
commit f8c1f4dd58
2 changed files with 14 additions and 2 deletions

View File

@ -75,6 +75,18 @@ namespace osu.Game.Modes.Osu.Objects.Drawables
ball.Position = slider.Curve.PositionAt(t); ball.Position = slider.Curve.PositionAt(t);
} }
protected override void CheckJudgement(bool userTriggered)
{
var j = Judgement as OsuJudgementInfo;
var sc = startCircle.Judgement as OsuJudgementInfo;
if (!userTriggered && Time.Current >= HitObject.EndTime)
{
j.Score = sc.Score;
j.Result = sc.Result;
}
}
protected override void UpdateState(ArmedState state) protected override void UpdateState(ArmedState state)
{ {
base.UpdateState(state); base.UpdateState(state);

View File

@ -17,7 +17,7 @@ namespace osu.Game.Modes.Objects.Drawables
public Container<DrawableHitObject> ChildObjects; public Container<DrawableHitObject> ChildObjects;
protected JudgementInfo Judgement; public JudgementInfo Judgement;
public abstract JudgementInfo CreateJudgementInfo(); public abstract JudgementInfo CreateJudgementInfo();
@ -84,7 +84,7 @@ namespace osu.Game.Modes.Objects.Drawables
protected virtual void CheckJudgement(bool userTriggered) protected virtual void CheckJudgement(bool userTriggered)
{ {
//todo: consider making abstract.
} }
protected override void Update() protected override void Update()