fix: make scaling consistent via sr

This commit is contained in:
tsunyoku
2023-03-24 20:30:56 +00:00
parent 2931e8bd9e
commit f60dbe4ecd
+15 -10
View File
@@ -257,12 +257,25 @@ impl<'m> OsuPP<'m> {
1.0 - (self.attributes.as_ref().unwrap().n_spinners as f32 / total_hits).powf(0.85); 1.0 - (self.attributes.as_ref().unwrap().n_spinners as f32 / total_hits).powf(0.85);
} }
let aim_value = self.compute_aim_value(total_hits, effective_miss_count); let mut aim_value = self.compute_aim_value(total_hits, effective_miss_count);
let speed_value = self.compute_speed_value(total_hits, effective_miss_count); let speed_value = self.compute_speed_value(total_hits, effective_miss_count);
let acc_value = self.compute_accuracy_value(total_hits); let acc_value = self.compute_accuracy_value(total_hits);
let mut acc_depression = 1.0;
if self.mods.rx() { if self.mods.rx() {
multiplier *= 0.97; multiplier *= 0.97;
let difficulty = self.attributes.as_ref().unwrap();
let streams_nerf = difficulty.aim_strain / difficulty.speed_strain;
if streams_nerf < 1.0 {
let acc_factor = (1.0 - self.acc.unwrap()).abs();
acc_depression = (0.84 - acc_factor).max(0.5);
if acc_depression > 0.0 {
aim_value *= acc_depression;
}
}
} }
let nodt_bonus = match !self.mods.change_speed() && self.mods.rx() { let nodt_bonus = match !self.mods.change_speed() && self.mods.rx() {
@@ -271,7 +284,7 @@ impl<'m> OsuPP<'m> {
}; };
let speed_factor = match self.mods.rx() { let speed_factor = match self.mods.rx() {
true => speed_value.powf(0.83), true => speed_value.powf(0.83 * acc_depression),
false => speed_value.powf(1.1), false => speed_value.powf(1.1),
}; };
@@ -336,14 +349,6 @@ impl<'m> OsuPP<'m> {
} }
} }
if self.mods.rx() {
let streams_nerf = aim_value / speed_value;
if streams_nerf < 1.0 {
pp *= (0.05 * self.acc.unwrap()) + 0.72;
}
}
OsuPerformanceAttributes { OsuPerformanceAttributes {
difficulty: self.attributes.unwrap(), difficulty: self.attributes.unwrap(),
pp_acc: acc_value as f64, pp_acc: acc_value as f64,