Skip to content

Commit 6ad899a

Browse files
authored
fix: clamp acc for ctb cards (#919)
1 parent 37ae349 commit 6ad899a

File tree

1 file changed

+3
-1
lines changed
  • bathbot-cards/src/skills

1 file changed

+3
-1
lines changed

bathbot-cards/src/skills/mod.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,9 @@ impl Skills {
163163

164164
let CatchPerformanceAttributes { difficulty, pp } = attrs;
165165

166-
let acc_ = score.accuracy as f64;
166+
// Values get messy for tiny accuracies so let's cap it
167+
// by the arbitrary value 10.
168+
let acc_ = score.accuracy.max(10.0) as f64;
167169

168170
let n_objects = (difficulty.n_fruits
169171
+ difficulty.n_droplets

0 commit comments

Comments
 (0)