From b0b41084f9da5ba985cdda1884ddd8cea49f246a Mon Sep 17 00:00:00 2001 From: Sacha <> Date: Tue, 10 Sep 2024 15:07:11 +0200 Subject: [PATCH] avant la fin --- miniP1.py | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/miniP1.py b/miniP1.py index fdb3261..6e378cf 100644 --- a/miniP1.py +++ b/miniP1.py @@ -11,5 +11,26 @@ class Presonnage: self.inventaire = ["bâton","potion"] if self.cat == "voleur": self.inventaire = ["dague","potion"] + if self.cat == "elfe": + self.inventaire = ["arc","potion"] + + def jet_attaque (self): if self.cat == "guerrier": - self.inventaire = ["épée","potion"] \ No newline at end of file + return = randint(1,20) + self.exp*10 + if self.cat == "magicien": + return = randint(1,20) + self.exp*10 + if self.cat == "voleur": + return = randint(1,20) + self.exp*3 + if self.cat == "elfe": + return = randint(1,20) + self.exp*8 + + def jet_defense (self): + if self.cat == "guerrier": + return = randint(1,20) + self.exp*8 + if self.cat == "magicien": + return = randint(1,20) + self.exp*7 + if self.cat == "voleur": + return = randint(1,20) + self.exp*9 + if self.cat == "elfe": + return = randint(1,20) + self.exp*10 + \ No newline at end of file