mirror of
https://github.com/osukey/osukey.git
synced 2025-07-02 16:59:53 +09:00
fix RepeatPoint animations
- FadeIn and -Out for RepeatPoints are now calculated instead of fixed values - TimePreempt is now cut down if too long for RepeatPoints following the first one to only show up to two RepeatPoints at any given time
This commit is contained in:
@ -72,12 +72,11 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
||||
|
||||
AddNested(InitialCircle);
|
||||
|
||||
var repeatDuration = s.Curve.Distance / s.Velocity;
|
||||
foreach (var tick in s.NestedHitObjects.OfType<SliderTick>())
|
||||
{
|
||||
var repeatStartTime = s.StartTime + tick.RepeatIndex * repeatDuration;
|
||||
var repeatStartTime = s.StartTime + tick.RepeatIndex * s.RepeatDuration;
|
||||
var fadeInTime = repeatStartTime + (tick.StartTime - repeatStartTime) / 2 - (tick.RepeatIndex == 0 ? HitObject.TimeFadein : HitObject.TimeFadein / 2);
|
||||
var fadeOutTime = repeatStartTime + repeatDuration;
|
||||
var fadeOutTime = repeatStartTime + s.RepeatDuration;
|
||||
|
||||
var drawableTick = new DrawableSliderTick(tick)
|
||||
{
|
||||
@ -92,15 +91,10 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
||||
|
||||
foreach (var repeatPoint in s.NestedHitObjects.OfType<RepeatPoint>())
|
||||
{
|
||||
var repeatStartTime = s.StartTime + repeatPoint.RepeatIndex * repeatDuration;
|
||||
var fadeInTime = repeatStartTime + (repeatPoint.StartTime - repeatStartTime) / 2 - (repeatPoint.RepeatIndex == 0 ? HitObject.TimeFadein : HitObject.TimeFadein / 2);
|
||||
var fadeOutTime = repeatStartTime + repeatDuration;
|
||||
|
||||
var drawableRepeatPoint = new DrawableRepeatPoint(repeatPoint, this)
|
||||
{
|
||||
FadeInTime = fadeInTime,
|
||||
FadeOutTime = fadeOutTime,
|
||||
Position = repeatPoint.Position,
|
||||
FadeInTime = repeatPoint.StartTime - s.RepeatDuration / 2,
|
||||
Position = repeatPoint.Position
|
||||
};
|
||||
|
||||
repeatPoints.Add(drawableRepeatPoint);
|
||||
|
Reference in New Issue
Block a user