diff --git a/main.py b/main.py new file mode 100644 index 0000000..b13ca6c --- /dev/null +++ b/main.py @@ -0,0 +1,16 @@ +class Personnage: + def __init__(self, nom, cat): + self.nom = nom + self.pdv = 20 + self.exp = 1 + self.cat = cat + match self.cat: + case "guerrier": + self.inventaire = ["epee"] + case "magicien": + self.inventaire = ["baton"] + case "voleur": + self.inventaire = ["dague"] + case "elfe": + self.inventaire = ["arc"] + self.inventaire.append("potion") \ No newline at end of file