Skip to content

Commit

Permalink
Fix rosupp DTNC pp calculation meme (#474)
Browse files Browse the repository at this point in the history
* fix rosupp DTNC pp calculation meme

* better comment

* move mods
  • Loading branch information
cmyui committed Aug 8, 2023
1 parent 0d817db commit a043f12
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions app/usecases/performance.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
from akatsuki_pp_py import Beatmap
from akatsuki_pp_py import Calculator

from app.constants.mods import Mods


@dataclass
class ScoreParams:
Expand Down Expand Up @@ -75,6 +77,11 @@ def calculate_performances(
# ):
# raise ValueError("Either acc OR 300/100/50/geki/katu/miss must be present")

# rosupp ignores NC and requires DT
if score.mods is not None:
if score.mods & Mods.NIGHTCORE:
score.mods |= Mods.DOUBLETIME

calculator = Calculator(
mode=score.mode,
mods=score.mods or 0,
Expand Down

0 comments on commit a043f12

Please sign in to comment.