mirror of
https://github.com/osukey/osukey.git
synced 2025-05-29 09:27:18 +09:00
Remove transformations
This commit is contained in:
parent
9477629a56
commit
1f6a4fa4b8
@ -5,6 +5,7 @@ using System;
|
|||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using osu.Framework.Allocation;
|
using osu.Framework.Allocation;
|
||||||
using osu.Framework.Bindables;
|
using osu.Framework.Bindables;
|
||||||
|
using osu.Framework.Extensions.IEnumerableExtensions;
|
||||||
using osu.Framework.Graphics;
|
using osu.Framework.Graphics;
|
||||||
using osu.Framework.Utils;
|
using osu.Framework.Utils;
|
||||||
using osu.Game.Rulesets.Objects.Drawables;
|
using osu.Game.Rulesets.Objects.Drawables;
|
||||||
@ -21,7 +22,7 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
|||||||
|
|
||||||
private double animDuration;
|
private double animDuration;
|
||||||
|
|
||||||
private readonly Drawable scaleContainer;
|
private readonly ReverseArrowPiece scaleContainer;
|
||||||
|
|
||||||
public DrawableSliderRepeat(SliderRepeat sliderRepeat, DrawableSlider drawableSlider)
|
public DrawableSliderRepeat(SliderRepeat sliderRepeat, DrawableSlider drawableSlider)
|
||||||
: base(sliderRepeat)
|
: base(sliderRepeat)
|
||||||
@ -79,6 +80,8 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
|||||||
case ArmedState.Hit:
|
case ArmedState.Hit:
|
||||||
this.FadeOut(animDuration, Easing.Out)
|
this.FadeOut(animDuration, Easing.Out)
|
||||||
.ScaleTo(Scale * 1.5f, animDuration, Easing.Out);
|
.ScaleTo(Scale * 1.5f, animDuration, Easing.Out);
|
||||||
|
scaleContainer.ShouldFollowBeats = false;
|
||||||
|
scaleContainer.Transforms.ForEach(t => scaleContainer.RemoveTransform(t));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -13,6 +13,8 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables.Pieces
|
|||||||
{
|
{
|
||||||
public class ReverseArrowPiece : BeatSyncedContainer
|
public class ReverseArrowPiece : BeatSyncedContainer
|
||||||
{
|
{
|
||||||
|
public bool ShouldFollowBeats = true;
|
||||||
|
|
||||||
public ReverseArrowPiece()
|
public ReverseArrowPiece()
|
||||||
{
|
{
|
||||||
Divisor = 2;
|
Divisor = 2;
|
||||||
@ -37,7 +39,10 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables.Pieces
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
protected override void OnNewBeat(int beatIndex, TimingControlPoint timingPoint, EffectControlPoint effectPoint, TrackAmplitudes amplitudes) =>
|
protected override void OnNewBeat(int beatIndex, TimingControlPoint timingPoint, EffectControlPoint effectPoint, TrackAmplitudes amplitudes)
|
||||||
Child.ScaleTo(1.3f).ScaleTo(1f, timingPoint.BeatLength, Easing.Out);
|
{
|
||||||
|
if (ShouldFollowBeats)
|
||||||
|
Child.ScaleTo(1.3f).ScaleTo(1f, timingPoint.BeatLength, Easing.Out);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user