1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-19 10:52:55 +08:00

Account angle change negatively on rewind

This commit is contained in:
iiSaLMaN 2019-09-08 16:14:14 +03:00
parent 3d8b27abfa
commit f5f2713a17

View File

@ -85,8 +85,10 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables.Pieces
public float BidirectionalRotation;
private int completeTick;
private double lastTime;
private bool updateCompleteTick() => completeTick != (completeTick = (int)(BidirectionalRotation / 360));
private bool rotationTransferred;
protected override void Update()
@ -112,6 +114,7 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables.Pieces
currentRotation += thisAngle - lastAngle;
BidirectionalRotation += Math.Abs(thisAngle - lastAngle) * Math.Sign(Time.Current - lastTime);
lastTime = Time.Current;
}
lastAngle = thisAngle;