Skip to content

Commit

Permalink
max and min value on stream nerf to prevent nan pp
Browse files Browse the repository at this point in the history
  • Loading branch information
Hazuki-san committed Oct 20, 2023
1 parent 748e615 commit 17878b9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/osu/pp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -459,8 +459,8 @@ impl OsuPpInner {
let mut aim_value = (5.0 * (self.attrs.aim / 0.0675).max(1.0) - 4.0).powi(3) / 100_000.0;

// stream aim nerf
if (self.attrs.aim / self.attrs.speed) < 1.03 && self.mods.rx() && self.mods.dt() {
aim_value *= self.attrs.aim / self.attrs.speed - 0.7
if (self.attrs.aim / self.attrs.speed) < 1.03 && self.mods.rx() {
aim_value *= (self.attrs.aim / self.attrs.speed - 0.7).max(0.2).min(0.9)
}

let total_hits = self.total_hits();
Expand Down

0 comments on commit 17878b9

Please sign in to comment.