2 Commits

Author SHA1 Message Date
barraux.a 1649aaffb0 patch de l'invetaire 2022-09-21 11:23:28 +02:00
BARRAUX Arthur ff01ebff66 legère update 2022-09-21 07:06:32 +02:00
+2 -1
View File
@@ -78,7 +78,7 @@ class Personnage(Animation):
self.pdv = 20
self.max_pdv = 20
self.xp = xp
self.inv = ['potion'for i in range(7)]
self.inv = ['potion'for i in range(2)]
self.shape = ['', '']
self.x = x
@@ -345,6 +345,7 @@ class App:
if position[0] > 0:
position[0] -= 1
elif key == getkey.keys.ENTER:
if self.character.inv.count('potion') > 0:
self.character.pdv += round((self.character.max_pdv - self.character.pdv) * 0.5)
if self.character.pdv > self.character.max_pdv:
self.character.pdv = self.character.max_pdv