New_High_Score method added.
This commit is contained in:
parent
42266d4b6c
commit
b6afb5450e
@ -74,6 +74,11 @@ class scoreboard():
|
|||||||
def Increase_Score(self, points = 1):
|
def Increase_Score(self, points = 1):
|
||||||
self.score += points
|
self.score += points
|
||||||
|
|
||||||
|
def New_High_Score(self):
|
||||||
|
for i, j in enumerate(self.oldScores):
|
||||||
|
if self.score > j: return i + 1
|
||||||
|
return None
|
||||||
|
|
||||||
def Update_Scores(self):
|
def Update_Scores(self):
|
||||||
# Update the scores
|
# Update the scores
|
||||||
for i, j in enumerate(self.oldScores):
|
for i, j in enumerate(self.oldScores):
|
||||||
|
Loading…
Reference in New Issue
Block a user