parse: remove bpm field from TimingPoint
This commit is contained in:
@@ -116,17 +116,14 @@ mod test {
|
||||
TimingPoint {
|
||||
time: 1.0,
|
||||
beat_len: 10.0,
|
||||
bpm: 0.0,
|
||||
},
|
||||
TimingPoint {
|
||||
time: 3.0,
|
||||
beat_len: 10.0,
|
||||
bpm: 0.0,
|
||||
},
|
||||
TimingPoint {
|
||||
time: 4.0,
|
||||
beat_len: 10.0,
|
||||
bpm: 0.0,
|
||||
},
|
||||
],
|
||||
difficulty_points: vec![
|
||||
|
||||
@@ -4,7 +4,6 @@ use std::cmp::Ordering;
|
||||
#[derive(Copy, Clone, Debug, PartialEq)]
|
||||
pub struct TimingPoint {
|
||||
pub beat_len: f32,
|
||||
pub bpm: f32, // TODO: Remove
|
||||
pub time: f32,
|
||||
}
|
||||
|
||||
|
||||
+1
-7
@@ -369,13 +369,7 @@ impl Beatmap {
|
||||
prev_diff = time;
|
||||
}
|
||||
} else {
|
||||
let point = TimingPoint {
|
||||
time,
|
||||
bpm: 60_000.0 / beat_len,
|
||||
beat_len,
|
||||
};
|
||||
|
||||
self.timing_points.push(point);
|
||||
self.timing_points.push(TimingPoint { time, beat_len });
|
||||
|
||||
if time < prev_time {
|
||||
unsorted_timings = true;
|
||||
|
||||
Reference in New Issue
Block a user