Linting
This commit is contained in:
@ -17,14 +17,15 @@ class Player(FightingEntity):
|
||||
def move_right(self) -> bool:
|
||||
return self.check_move(self.y, self.x + 1, True)
|
||||
|
||||
currentXP: int
|
||||
maxXP: int
|
||||
current_xp: int
|
||||
max_xp: int
|
||||
|
||||
def level_up(self):
|
||||
if currentXP>maxXP :
|
||||
self.level+=1
|
||||
currentXP = 0
|
||||
maxXP = self.level*10
|
||||
def addXP(self, xp) :
|
||||
currentXP+=xp
|
||||
def level_up(self) -> None:
|
||||
if self.current_xp > self.max_xp:
|
||||
self.level += 1
|
||||
self.current_xp = 0
|
||||
self.max_xp = self.level * 10
|
||||
|
||||
def add_xp(self, xp: int) -> None:
|
||||
self.current_xp += xp
|
||||
self.level_up()
|
||||
|
Reference in New Issue
Block a user