mirror of
https://github.com/osukey/osukey.git
synced 2025-05-29 17:37:23 +09:00
Fix reference points being wrongly selected
This commit is contained in:
parent
efae00c149
commit
cee8bb50c9
@ -80,7 +80,7 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables
|
||||
var curve = drawableSlider.CurrentCurve;
|
||||
if (curve.Count < 3 || curve.All(p => p == Position))
|
||||
return;
|
||||
var referencePoint = curve[isEndRepeat ? curve.IndexOf(Position) - 1 : curve.LastIndexOf(Position) + 1];
|
||||
var referencePoint = curve[isEndRepeat ? curve.IndexOf(Position, curve.Count - 2) - 1 : curve[0] == curve[1] ? 2 : 1];
|
||||
Rotation = MathHelper.RadiansToDegrees((float)Math.Atan2(referencePoint.Y - Position.Y, referencePoint.X - Position.X));
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user