1
0
mirror of https://github.com/ppy/osu.git synced 2025-01-14 03:03:02 +08:00

Fix nullref due to missing controlPoints.

This commit is contained in:
Dean Herbert 2017-02-17 15:27:42 +09:00
parent ecb840e26f
commit 0b922365bb
No known key found for this signature in database
GPG Key ID: 46D71BF4958ABB49
2 changed files with 2 additions and 2 deletions

View File

@ -59,7 +59,7 @@ namespace osu.Game.Modes.Osu.Objects
var velocityAdjustment = overridePoint?.VelocityAdjustment ?? 1;
var baseVelocity = 100 * baseDifficulty.SliderMultiplier;
Velocity = baseVelocity / (timingPoint.BeatLength * velocityAdjustment);
Velocity = baseVelocity / ((timingPoint?.BeatLength ?? 500) * velocityAdjustment);
TickDistance = baseVelocity / (baseDifficulty.SliderTickRate * velocityAdjustment);
}

View File

@ -39,7 +39,7 @@ namespace osu.Game.Beatmaps
ControlPoint timingPoint = null;
foreach (var controlPoint in ControlPoints)
if (controlPoint.Time <= time)
if (controlPoint.Time <= time || timingPoint == null)
{
if (controlPoint.TimingChange)
{