mirror of
https://github.com/ppy/osu.git
synced 2025-02-21 21:32:55 +08:00
Update spm value when spinner not active.
This commit is contained in:
parent
3de42ee405
commit
134e1299bb
@ -112,20 +112,20 @@ namespace osu.Game.Rulesets.Osu.Objects.Drawables.Pieces
|
|||||||
|
|
||||||
currentRotation += thisAngle - lastAngle;
|
currentRotation += thisAngle - lastAngle;
|
||||||
RotationAbsolute += Math.Abs(thisAngle - lastAngle);
|
RotationAbsolute += Math.Abs(thisAngle - lastAngle);
|
||||||
if (rotations.Count > 0)
|
|
||||||
{
|
|
||||||
float rotationFrom = rotations.Peek();
|
|
||||||
double timeFrom = times.Peek();
|
|
||||||
while (Time.Current - times.Peek() > spm_count_duration)
|
|
||||||
{
|
|
||||||
rotationFrom = rotations.Dequeue();
|
|
||||||
timeFrom = times.Dequeue();
|
|
||||||
}
|
|
||||||
SpinsPerMinute = (currentRotation - rotationFrom) / (Time.Current - timeFrom) * 1000 * 60 / 360;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
lastAngle = thisAngle;
|
lastAngle = thisAngle;
|
||||||
|
if (rotations.Count > 0)
|
||||||
|
{
|
||||||
|
float rotationFrom = rotations.Peek();
|
||||||
|
double timeFrom = times.Peek();
|
||||||
|
while (Time.Current - times.Peek() > spm_count_duration)
|
||||||
|
{
|
||||||
|
rotationFrom = rotations.Dequeue();
|
||||||
|
timeFrom = times.Dequeue();
|
||||||
|
}
|
||||||
|
SpinsPerMinute = (currentRotation - rotationFrom) / (Time.Current - timeFrom) * 1000 * 60 / 360;
|
||||||
|
}
|
||||||
rotations.Enqueue(currentRotation);
|
rotations.Enqueue(currentRotation);
|
||||||
times.Enqueue(Time.Current);
|
times.Enqueue(Time.Current);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user