Add reading of KiaiMode/OmitFirstBarLine from legacy control points.

This commit is contained in:
smoogipooo 2017-03-17 13:23:39 +09:00
parent 163a21a7bf
commit a06c195e1f
2 changed files with 4 additions and 1 deletions

View File

@ -197,7 +197,7 @@ private void handleTimingPoints(Beatmap beatmap, string val)
if (split.Length > 2)
{
//int kiaiFlags = split.Length > 7 ? Convert.ToInt32(split[7], NumberFormatInfo.InvariantInfo) : 0;
int effectFlags = split.Length > 7 ? Convert.ToInt32(split[7], NumberFormatInfo.InvariantInfo) : 0;
double beatLength = double.Parse(split[1].Trim(), NumberFormatInfo.InvariantInfo);
cp = new ControlPoint
{
@ -205,6 +205,8 @@ private void handleTimingPoints(Beatmap beatmap, string val)
BeatLength = beatLength > 0 ? beatLength : 0,
VelocityAdjustment = beatLength < 0 ? -beatLength / 100.0 : 1,
TimingChange = split.Length <= 6 || split[6][0] == '1',
KiaiMode = (effectFlags & 1) > 0,
OmitFirstBarLine = (effectFlags & 8) > 0
};
}

View File

@ -16,6 +16,7 @@ public class ControlPoint
public double VelocityAdjustment;
public bool TimingChange;
public bool KiaiMode;
public bool OmitFirstBarLine;
}