mirror of
https://github.com/ppy/osu.git
synced 2025-01-13 14:52:57 +08:00
Merge pull request #10274 from peppy/autoplay-fix-empty-generation
Fix autoplay generators failing on empty hitobjects lists
This commit is contained in:
commit
895828c06a
@ -31,6 +31,9 @@ namespace osu.Game.Rulesets.Catch.Replays
|
||||
|
||||
public override Replay Generate()
|
||||
{
|
||||
if (Beatmap.HitObjects.Count == 0)
|
||||
return Replay;
|
||||
|
||||
// todo: add support for HT DT
|
||||
const double dash_speed = Catcher.BASE_SPEED;
|
||||
const double movement_speed = dash_speed / 2;
|
||||
|
@ -46,6 +46,9 @@ namespace osu.Game.Rulesets.Mania.Replays
|
||||
|
||||
public override Replay Generate()
|
||||
{
|
||||
if (Beatmap.HitObjects.Count == 0)
|
||||
return Replay;
|
||||
|
||||
var pointGroups = generateActionPoints().GroupBy(a => a.Time).OrderBy(g => g.First().Time);
|
||||
|
||||
var actions = new List<ManiaAction>();
|
||||
|
@ -72,6 +72,9 @@ namespace osu.Game.Rulesets.Osu.Replays
|
||||
|
||||
public override Replay Generate()
|
||||
{
|
||||
if (Beatmap.HitObjects.Count == 0)
|
||||
return Replay;
|
||||
|
||||
buttonIndex = 0;
|
||||
|
||||
AddFrameToReplay(new OsuReplayFrame(-100000, new Vector2(256, 500)));
|
||||
|
@ -30,6 +30,9 @@ namespace osu.Game.Rulesets.Taiko.Replays
|
||||
|
||||
public override Replay Generate()
|
||||
{
|
||||
if (Beatmap.HitObjects.Count == 0)
|
||||
return Replay;
|
||||
|
||||
bool hitButton = true;
|
||||
|
||||
Frames.Add(new TaikoReplayFrame(-100000));
|
||||
|
Loading…
Reference in New Issue
Block a user