|
|
@ -270,7 +270,7 @@ class App: |
|
|
|
|
|
|
|
ennemi = random.randint(0, 3) |
|
|
|
cat = ['guerrier', 'elfe', 'magicien', 'voleur'] |
|
|
|
self.opponent[ennemi].__init__(self.opponent[ennemi].nom, 120, 5, cat[ennemi], random.randint(max(1, self.character.xp - 2), self.character.xp+1, True)) |
|
|
|
self.opponent[ennemi].__init__(self.opponent[ennemi].nom, 120, 5, cat[ennemi], random.randint(max(1, self.character.xp - 2), self.character.xp+1), True) |
|
|
|
self.opponent[ennemi].change_max_pdv(20 + 5 * (self.opponent[ennemi].xp-1)) |
|
|
|
self.opponent[ennemi].change_pdv(self.opponent[ennemi].max_pdv - self.opponent[ennemi].pdv) |
|
|
|
self.opponent[ennemi].move(-40, 0, 4) |
|
|
@ -295,9 +295,10 @@ class App: |
|
|
|
self.character.add_potion() |
|
|
|
|
|
|
|
ennemi = random.randint(0, 3) |
|
|
|
self.opponent[ennemi].__init__(self.opponent[ennemi].nom, 120, 5, random.randint(max(self.character.xp - 3, 1), self.character.xp+1), True) |
|
|
|
cat = ['guerrier', 'elfe', 'magicien', 'voleur'] |
|
|
|
self.opponent[ennemi].__init__(self.opponent[ennemi].nom, 120, 5, cat[ennemi], random.randint(max(self.character.xp - 3, 1), self.character.xp+1), True) |
|
|
|
self.opponent[ennemi].change_max_pdv(20 + 5 * (self.opponent[ennemi].xp-1)) |
|
|
|
self.opponent[ennemi].change_pdv(self.opponent[ennemi].max_pdv - self.opponent[ennemi].max_pdv) |
|
|
|
self.opponent[ennemi].change_pdv(self.opponent[ennemi].max_pdv - self.opponent[ennemi].pdv) |
|
|
|
self.opponent[ennemi].move(-40, 0, 4) |
|
|
|
return ennemi |
|
|
|
else: |
|
|
|