added max_combo method for osu & taiko difficulty attributes

This commit is contained in:
MaxOhn
2021-11-23 03:09:55 +01:00
parent 86cee5ee88
commit bfc0188c61
3 changed files with 17 additions and 0 deletions
+1
View File
@@ -13,6 +13,7 @@
- Added `OsuGradualPerformanceAttributes`. Suitable to calculate the performance on a map after every or every few objects instead of using `OsuPP` over and over.
- Fixed incorrect attributes on maps with only 1 or 2 hit objects for all modes
- [BREAKING] Replaced field `FruitsDifficultyAttributes::max_combo` by a method with the same name
- Added methods `TaikoDifficultyAttributes::max_combo` and `OsuDifficultyAttributes::max_combo`
# v0.3.0
+8
View File
@@ -459,6 +459,14 @@ pub struct OsuDifficultyAttributes {
pub max_combo: usize,
}
impl OsuDifficultyAttributes {
/// Return the maximum combo.
#[inline]
pub fn max_combo(&self) -> usize {
self.max_combo
}
}
/// The result of a performance calculation on an osu!standard map.
#[derive(Clone, Debug, Default, PartialEq)]
pub struct OsuPerformanceAttributes {
+8
View File
@@ -232,6 +232,14 @@ pub struct TaikoDifficultyAttributes {
pub max_combo: usize,
}
impl TaikoDifficultyAttributes {
/// Return the maximum combo.
#[inline]
pub fn max_combo(&self) -> usize {
self.max_combo
}
}
/// The result of a performance calculation on an osu!taiko map.
#[derive(Clone, Debug, Default)]
pub struct TaikoPerformanceAttributes {