1
0
mirror of https://github.com/ppy/osu.git synced 2025-02-06 23:12:54 +08:00

fix div by zeros

This commit is contained in:
danielthirtle 2025-01-14 01:17:01 +13:00
parent 898f197091
commit 9ea844a464

View File

@ -434,7 +434,7 @@ namespace osu.Game.Rulesets.Osu.Difficulty
private double calculateEstimatedSliderbreaks(double topWeightedSliderFactor, OsuDifficultyAttributes attributes) private double calculateEstimatedSliderbreaks(double topWeightedSliderFactor, OsuDifficultyAttributes attributes)
{ {
if (!usingClassicSliderAccuracy) if (!usingClassicSliderAccuracy || countOk == 0)
return 0; return 0;
double missedComboPercent = 1.0 - (double)scoreMaxCombo / attributes.MaxCombo; double missedComboPercent = 1.0 - (double)scoreMaxCombo / attributes.MaxCombo;