osu & fruits: added unit test for SliderState

This commit is contained in:
MaxOhn
2021-01-22 16:35:50 +01:00
parent 52979f790f
commit 91819063c6
5 changed files with 105 additions and 0 deletions
+1
View File
@@ -126,6 +126,7 @@ pub(crate) struct DifficultyHitObject<'o> {
}
impl<'o> DifficultyHitObject<'o> {
#[inline]
fn new(base: &'o HitObject, prev: &'o HitObject, cs: f32, clock_rate: f32) -> Self {
let x_divisor = 512.0 / cs;
let column = (base.pos.x / x_divisor).floor() as usize;
+1
View File
@@ -181,6 +181,7 @@ impl ManiaAttributeProvider for StarResult {
}
impl ManiaAttributeProvider for PpResult {
#[inline]
fn attributes(self) -> Option<f32> {
self.attributes.attributes()
}