-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into dont-round-sv
- Loading branch information
Showing
138 changed files
with
1,284 additions
and
1,055 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,8 @@ | ||
// Copyright (c) ppy Pty Ltd <[email protected]>. Licensed under the MIT Licence. | ||
// See the LICENCE file in the repository root for full licence text. | ||
|
||
using System; | ||
using System.Collections.Generic; | ||
using NUnit.Framework; | ||
using osu.Framework.Graphics; | ||
using osu.Game.Rulesets.Mania.Beatmaps; | ||
using osu.Game.Rulesets.Mania.Objects; | ||
using osu.Game.Rulesets.Mania.UI; | ||
|
@@ -16,37 +14,35 @@ public partial class TestSceneBarLine : ManiaSkinnableTestScene | |
[Test] | ||
public void TestMinor() | ||
{ | ||
AddStep("Create barlines", () => recreate()); | ||
AddStep("Create barlines", recreate); | ||
} | ||
|
||
private void recreate(Func<IEnumerable<BarLine>>? createBarLines = null) | ||
private void recreate() | ||
{ | ||
var stageDefinitions = new List<StageDefinition> | ||
{ | ||
new StageDefinition(4), | ||
}; | ||
|
||
SetContents(_ => new ManiaPlayfield(stageDefinitions).With(s => | ||
SetContents(_ => | ||
{ | ||
if (createBarLines != null) | ||
{ | ||
var barLines = createBarLines(); | ||
|
||
foreach (var b in barLines) | ||
s.Add(b); | ||
var maniaPlayfield = new ManiaPlayfield(stageDefinitions); | ||
|
||
return; | ||
} | ||
|
||
for (int i = 0; i < 64; i++) | ||
// Must be scheduled so the pool is loaded before we try and retrieve from it. | ||
Schedule(() => | ||
{ | ||
s.Add(new BarLine | ||
for (int i = 0; i < 64; i++) | ||
{ | ||
StartTime = Time.Current + i * 500, | ||
Major = i % 4 == 0, | ||
}); | ||
} | ||
})); | ||
maniaPlayfield.Add(new BarLine | ||
{ | ||
StartTime = Time.Current + i * 500, | ||
Major = i % 4 == 0, | ||
}); | ||
} | ||
}); | ||
|
||
return maniaPlayfield; | ||
}); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.