refactor!: add is_convert to taiko&mania diff attrs
This commit is contained in:
@@ -139,6 +139,7 @@ impl<'map> ManiaStars<'map> {
|
||||
hit_window,
|
||||
max_combo,
|
||||
n_objects,
|
||||
is_convert,
|
||||
}
|
||||
}
|
||||
|
||||
@@ -239,6 +240,8 @@ pub struct ManiaDifficultyAttributes {
|
||||
pub n_objects: usize,
|
||||
/// The maximum achievable combo.
|
||||
pub max_combo: usize,
|
||||
/// Whether the [`Beatmap`] was a convert i.e. an osu!standard map.
|
||||
pub is_convert: bool,
|
||||
}
|
||||
|
||||
impl ManiaDifficultyAttributes {
|
||||
@@ -253,6 +256,12 @@ impl ManiaDifficultyAttributes {
|
||||
pub fn n_objects(&self) -> usize {
|
||||
self.n_objects
|
||||
}
|
||||
|
||||
/// Whether the [`Beatmap`] was a convert i.e. an osu!standard map.
|
||||
#[inline]
|
||||
pub fn is_convert(&self) -> bool {
|
||||
self.is_convert
|
||||
}
|
||||
}
|
||||
|
||||
/// The result of a performance calculation on an osu!mania map.
|
||||
@@ -290,6 +299,12 @@ impl ManiaPerformanceAttributes {
|
||||
pub fn n_objects(&self) -> usize {
|
||||
self.difficulty.n_objects
|
||||
}
|
||||
|
||||
/// Whether the [`Beatmap`] was a convert i.e. an osu!standard map.
|
||||
#[inline]
|
||||
pub fn is_convert(&self) -> bool {
|
||||
self.difficulty.is_convert
|
||||
}
|
||||
}
|
||||
|
||||
impl From<ManiaPerformanceAttributes> for ManiaDifficultyAttributes {
|
||||
|
||||
Reference in New Issue
Block a user