mirror of
https://github.com/ppy/osu.git
synced 2025-01-12 20:22:55 +08:00
Use Parsing helpers
This commit is contained in:
parent
f453675838
commit
fb0bba9b37
@ -2,10 +2,10 @@
|
|||||||
// See the LICENCE file in the repository root for full licence text.
|
// See the LICENCE file in the repository root for full licence text.
|
||||||
|
|
||||||
using System;
|
using System;
|
||||||
using System.Globalization;
|
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using osu.Game.Beatmaps;
|
using osu.Game.Beatmaps;
|
||||||
|
using osu.Game.Beatmaps.Formats;
|
||||||
using osu.Game.Beatmaps.Legacy;
|
using osu.Game.Beatmaps.Legacy;
|
||||||
using osu.Game.IO.Legacy;
|
using osu.Game.IO.Legacy;
|
||||||
using osu.Game.Replays;
|
using osu.Game.Replays;
|
||||||
@ -225,7 +225,7 @@ namespace osu.Game.Scoring.Legacy
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
var diff = float.Parse(split[0]);
|
var diff = Parsing.ParseFloat(split[0]);
|
||||||
lastTime += diff;
|
lastTime += diff;
|
||||||
|
|
||||||
// Todo: At some point we probably want to rewind and play back the negative-time frames
|
// Todo: At some point we probably want to rewind and play back the negative-time frames
|
||||||
@ -234,9 +234,9 @@ namespace osu.Game.Scoring.Legacy
|
|||||||
continue;
|
continue;
|
||||||
|
|
||||||
replay.Frames.Add(convertFrame(new LegacyReplayFrame(lastTime,
|
replay.Frames.Add(convertFrame(new LegacyReplayFrame(lastTime,
|
||||||
float.Parse(split[1], CultureInfo.InvariantCulture),
|
Parsing.ParseFloat(split[1], Parsing.MAX_COORDINATE_VALUE),
|
||||||
float.Parse(split[2], CultureInfo.InvariantCulture),
|
Parsing.ParseFloat(split[2], Parsing.MAX_COORDINATE_VALUE),
|
||||||
(ReplayButtonState)int.Parse(split[3]))));
|
(ReplayButtonState)Parsing.ParseInt(split[3]))));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user