mirror of
https://github.com/ppy/osu.git
synced 2025-01-06 08:22:56 +08:00
Move autoplay mod to a less overridable location
This commit is contained in:
parent
2945fef62d
commit
fc668d8a74
@ -52,12 +52,6 @@ namespace osu.Game.Tests.Visual
|
|||||||
if (!AllowFail)
|
if (!AllowFail)
|
||||||
Mods.Value = new[] { ruleset.GetAllMods().First(m => m is ModNoFail) };
|
Mods.Value = new[] { ruleset.GetAllMods().First(m => m is ModNoFail) };
|
||||||
|
|
||||||
Player = CreatePlayer(ruleset);
|
|
||||||
LoadScreen(Player);
|
|
||||||
}
|
|
||||||
|
|
||||||
protected virtual Player CreatePlayer(Ruleset ruleset)
|
|
||||||
{
|
|
||||||
if (Autoplay)
|
if (Autoplay)
|
||||||
{
|
{
|
||||||
var mod = ruleset.GetAutoplayMod();
|
var mod = ruleset.GetAutoplayMod();
|
||||||
@ -65,7 +59,10 @@ namespace osu.Game.Tests.Visual
|
|||||||
Mods.Value = Mods.Value.Concat(mod.Yield()).ToArray();
|
Mods.Value = Mods.Value.Concat(mod.Yield()).ToArray();
|
||||||
}
|
}
|
||||||
|
|
||||||
return new TestPlayer(false, false);
|
Player = CreatePlayer(ruleset);
|
||||||
|
LoadScreen(Player);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
protected virtual Player CreatePlayer(Ruleset ruleset) => new TestPlayer(false, false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user