feature-gated modes and osu!standard versions
This commit is contained in:
+4
-2
@@ -1,3 +1,5 @@
|
||||
#![cfg(feature = "mania")]
|
||||
|
||||
mod pp;
|
||||
mod strain;
|
||||
|
||||
@@ -151,7 +153,7 @@ mod tests {
|
||||
#[test]
|
||||
#[ignore]
|
||||
fn mania_single() {
|
||||
let file = match File::open("./maps/1529790.osu") {
|
||||
let file = match File::open("./maps/1355822.osu") {
|
||||
Ok(file) => file,
|
||||
Err(why) => panic!("Could not open file: {}", why),
|
||||
};
|
||||
@@ -161,7 +163,7 @@ mod tests {
|
||||
Err(why) => panic!("Error while parsing map: {}", why),
|
||||
};
|
||||
|
||||
let result = ManiaPP::new(&map).mods(0).calculate();
|
||||
let result = ManiaPP::new(&map).mods(256).calculate();
|
||||
|
||||
println!("Stars: {}", result.stars());
|
||||
println!("PP: {}", result.pp());
|
||||
|
||||
@@ -19,6 +19,7 @@ impl ManiaStarProvider for DifficultyAttributes {
|
||||
|
||||
impl ManiaStarProvider for StarResult {
|
||||
fn attributes(self) -> Option<f32> {
|
||||
#[allow(irrefutable_let_patterns)]
|
||||
if let Self::Mania(attributes) = self {
|
||||
Some(attributes.stars)
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user