mirror of
https://github.com/ppy/osu.git
synced 2025-01-06 08:22:56 +08:00
Use existing hit objects instead of defining own
This commit is contained in:
parent
d4bde0afe5
commit
a59dabca7e
@ -55,25 +55,13 @@ namespace osu.Game.Rulesets.Catch.Tests
|
|||||||
|
|
||||||
private void performJudgement(HitResult type, Judgement judgement = null)
|
private void performJudgement(HitResult type, Judgement judgement = null)
|
||||||
{
|
{
|
||||||
var judgedObject = new TestDrawableCatchHitObject(new TestCatchHitObject());
|
var judgedObject = new DrawableFruit(new Fruit()) { AccentColour = { Value = judgedObjectColour } };
|
||||||
|
|
||||||
var result = new JudgementResult(judgedObject.HitObject, judgement ?? new Judgement()) { Type = type };
|
var result = new JudgementResult(judgedObject.HitObject, judgement ?? new Judgement()) { Type = type };
|
||||||
scoreProcessor.ApplyResult(result);
|
scoreProcessor.ApplyResult(result);
|
||||||
|
|
||||||
foreach (var counter in CreatedDrawables.Cast<CatchComboDisplay>())
|
foreach (var counter in CreatedDrawables.Cast<CatchComboDisplay>())
|
||||||
counter.OnNewResult(judgedObject, result);
|
counter.OnNewResult(judgedObject, result);
|
||||||
}
|
}
|
||||||
|
|
||||||
private class TestDrawableCatchHitObject : DrawableCatchHitObject
|
|
||||||
{
|
|
||||||
public TestDrawableCatchHitObject(CatchHitObject hitObject)
|
|
||||||
: base(hitObject)
|
|
||||||
{
|
|
||||||
AccentColour.Value = Color4.White;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private class TestCatchHitObject : CatchHitObject
|
|
||||||
{
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user