capped healing to max_health

This commit is contained in:
Lief9100
2020-04-24 20:06:15 -07:00
parent 173fb84f07
commit 633e1e6450

View File

@@ -169,6 +169,8 @@ class Player(Mob):
def heal(self):
self.health+=Config.HEAL_AMOUNT
if self.health > self.max_health:
self.health = self.max_health
def harden(self):
self.armor+=Config.ARMOR_AMOUNT