points to prop
This commit is contained in:
@@ -25,7 +25,16 @@ class PlayerState:
|
||||
display = None
|
||||
specialDisplay = None
|
||||
id = 0
|
||||
points = 0
|
||||
_points = 0
|
||||
@property
|
||||
def points(self):
|
||||
return self._points
|
||||
|
||||
@points.setter
|
||||
def points(self, points):
|
||||
self._points = points
|
||||
self.display.printScore(self.points)
|
||||
|
||||
bonus = 0
|
||||
bonusMultiplierIter = iter(BONUS_MULTIPLIER)
|
||||
bonusMultiplier = 1
|
||||
@@ -225,7 +234,6 @@ class PlayerState:
|
||||
self.hasBallScored = True
|
||||
|
||||
self.points += points
|
||||
self.display.printScore(self.points)
|
||||
|
||||
def addBall(self):
|
||||
self.ballsLeft += 1
|
||||
|
||||
Reference in New Issue
Block a user