diff --git a/osu.Desktop.VisualTests/Tests/TestCaseGamefield.cs b/osu.Desktop.VisualTests/Tests/TestCaseGamefield.cs index cb15558ec3..1049a8818a 100644 --- a/osu.Desktop.VisualTests/Tests/TestCaseGamefield.cs +++ b/osu.Desktop.VisualTests/Tests/TestCaseGamefield.cs @@ -18,6 +18,7 @@ using osu.Game.Rulesets.Taiko.UI; using System.Collections.Generic; using osu.Desktop.VisualTests.Beatmaps; using osu.Framework.Allocation; +using osu.Game.Beatmaps.Timing; namespace osu.Desktop.VisualTests.Tests { @@ -52,6 +53,12 @@ namespace osu.Desktop.VisualTests.Tests time += RNG.Next(50, 500); } + TimingInfo timing = new TimingInfo(); + timing.ControlPoints.Add(new ControlPoint + { + BeatLength = 200 + }); + WorkingBeatmap beatmap = new TestWorkingBeatmap(new Beatmap { HitObjects = objects, @@ -64,8 +71,9 @@ namespace osu.Desktop.VisualTests.Tests Artist = @"Unknown", Title = @"Sample Beatmap", Author = @"peppy", - } - } + }, + }, + TimingInfo = timing }); Add(new Drawable[] diff --git a/osu.Game.Rulesets.Mania/Timing/TimeRelativeContainer.cs b/osu.Game.Rulesets.Mania/Timing/TimeRelativeContainer.cs index 06e7cd1f53..466639fc02 100644 --- a/osu.Game.Rulesets.Mania/Timing/TimeRelativeContainer.cs +++ b/osu.Game.Rulesets.Mania/Timing/TimeRelativeContainer.cs @@ -52,7 +52,7 @@ namespace osu.Game.Rulesets.Mania.Timing return; } - var section = drawableTimingSections.LastOrDefault(t => t.CanContain(drawable)) ?? drawableTimingSections.First(); + var section = drawableTimingSections.LastOrDefault(t => t.CanContain(drawable)) ?? drawableTimingSections.FirstOrDefault(); if (section == null) throw new Exception("Could not find suitable timing section to add object to."); diff --git a/osu.Game/Beatmaps/Timing/ControlPoint.cs b/osu.Game/Beatmaps/Timing/ControlPoint.cs index ea152ccb39..fbae7d9614 100644 --- a/osu.Game/Beatmaps/Timing/ControlPoint.cs +++ b/osu.Game/Beatmaps/Timing/ControlPoint.cs @@ -7,7 +7,7 @@ namespace osu.Game.Beatmaps.Timing { public string SampleBank; public int SampleVolume; - public TimeSignatures TimeSignature; + public TimeSignatures TimeSignature = TimeSignatures.SimpleQuadruple; public double Time; public double BeatLength = 500; public double SpeedMultiplier = 1;