1
0
mirror of https://github.com/ppy/osu.git synced 2024-11-06 06:57:39 +08:00
This commit is contained in:
smoogipoo 2020-04-27 12:01:31 +09:00
parent bc6b02664f
commit dd36b839b9
2 changed files with 20 additions and 20 deletions

View File

@ -24,8 +24,6 @@ namespace osu.Game.Rulesets.Taiko.Objects.Drawables
FillMode = FillMode.Fit;
}
public override bool DisplayResult => false;
protected override SkinnableDrawable CreateMainPiece() => new SkinnableDrawable(new TaikoSkinComponent(TaikoSkinComponents.DrumRollTick),
_ => new TickPiece
{

View File

@ -181,29 +181,11 @@ namespace osu.Game.Rulesets.Taiko.UI
}
}
private void playDrumrollHit(DrawableDrumRollTick drumrollTick)
{
TaikoAction action = drumrollTick.JudgedAction;
bool isStrong = drumrollTick.HitObject.IsStrong;
double time = drumrollTick.HitObject.GetEndTime();
DrawableHit drawableHit;
if (action == TaikoAction.LeftRim || action == TaikoAction.RightRim)
drawableHit = new DrawableFlyingRimHit(time, isStrong);
else
drawableHit = new DrawableFlyingCentreHit(time, isStrong);
drumRollHitContainer.Add(drawableHit);
}
internal void OnNewResult(DrawableHitObject judgedObject, JudgementResult result)
{
if (!DisplayJudgements.Value)
return;
if ((judgedObject is DrawableDrumRollTick) && result.Type != HitResult.Miss)
playDrumrollHit((DrawableDrumRollTick)judgedObject);
if (!judgedObject.DisplayResult)
return;
@ -214,6 +196,11 @@ namespace osu.Game.Rulesets.Taiko.UI
hitExplosionContainer.Children.FirstOrDefault(e => e.JudgedObject == ((DrawableStrongNestedHit)judgedObject).MainObject)?.VisualiseSecondHit();
break;
case TaikoDrumRollTickJudgement _:
if (result.IsHit)
playDrumrollHit((DrawableDrumRollTick)judgedObject);
break;
default:
judgementContainer.Add(new DrawableTaikoJudgement(result, judgedObject)
{
@ -237,6 +224,21 @@ namespace osu.Game.Rulesets.Taiko.UI
}
}
private void playDrumrollHit(DrawableDrumRollTick drumrollTick)
{
TaikoAction action = drumrollTick.JudgedAction;
bool isStrong = drumrollTick.HitObject.IsStrong;
double time = drumrollTick.HitObject.GetEndTime();
DrawableHit drawableHit;
if (action == TaikoAction.LeftRim || action == TaikoAction.RightRim)
drawableHit = new DrawableFlyingRimHit(time, isStrong);
else
drawableHit = new DrawableFlyingCentreHit(time, isStrong);
drumRollHitContainer.Add(drawableHit);
}
private class ProxyContainer : LifetimeManagementContainer
{
public new MarginPadding Padding