private void onNewResult(DrawableHitObject obj, JudgementResult result) { if (!(obj is DrawableDrumRollTick)) return; if (result.Type > HitResult.Miss) rollingHits++; else rollingHits--; rollingHits = MathHelper.Clamp(rollingHits, 0, rolling_hits_for_engaged_colour); Color4 newColour = Interpolation.ValueAt((float)rollingHits / rolling_hits_for_engaged_colour, colourIdle, colourEngaged, 0, 1); MainPiece.FadeAccent(newColour, 100); }
private void onTickJudgement(DrawableHitObject obj, Judgement judgement) { if (judgement.Result > HitResult.Miss) { rollingHits++; } else { rollingHits--; } rollingHits = MathHelper.Clamp(rollingHits, 0, rolling_hits_for_dark_accent); Color4 newAccent = Interpolation.ValueAt((float)rollingHits / rolling_hits_for_dark_accent, AccentColour, accentDarkColour, 0, 1); MainPiece.FadeAccent(newAccent, 100); }
private void onTickJudgement(DrawableHitObject obj, Judgement judgement) { if (judgement.Result > HitResult.Miss) { rollingHits++; } else { rollingHits--; } rollingHits = MathHelper.Clamp(rollingHits, 0, rolling_hits_for_engaged_colour); Color4 newColour = Interpolation.ValueAt((float)rollingHits / rolling_hits_for_engaged_colour, colourIdle, colourEngaged, 0, 1); MainPiece.FadeAccent(newColour, 100); }