Fail rank if no score data
This commit is contained in:
parent
8cfa8c7907
commit
3847689257
|
@ -176,10 +176,11 @@ class Replay:
|
||||||
def get_possible_hits(self):
|
def get_possible_hits(self):
|
||||||
return self.get_hits() + self._score_miss.value
|
return self.get_hits() + self._score_miss.value
|
||||||
|
|
||||||
def get_rank(self): # We dont give out F ranks around here
|
def get_rank(self):
|
||||||
hits = self.get_possible_hits()
|
hits = self.get_possible_hits()
|
||||||
if hits == 0:
|
if hits == 0:
|
||||||
raise Exception("Can not calculate rank without any score data")
|
print("Can not calculate rank without any score data (Defaulting to Fail)")
|
||||||
|
return osuRanks.F
|
||||||
|
|
||||||
r300 = self._score_300s.value / hits
|
r300 = self._score_300s.value / hits
|
||||||
r50 = self._score_50s.value / hits
|
r50 = self._score_50s.value / hits
|
||||||
|
|
Loading…
Reference in New Issue
Block a user