class User:
def __init__(self, attack, movement):
print("logged in\n\n\n\n")
self.attack = attack
self.movement = movement
def attack(self):
print(f" WTF##attack{self.attack()}\n\n\n")
class Wizard(User):
def __init__(self, name, age, attack, movement: 100):
self.name = name
self.age = age
super().__init__(attack, movement)
print(f"attack of wizard:{self.attack}\n\n")
print(f"movement speed is :{self.movement}\n\n")
class Archer(User):
def __init__(self, arrows, attack, movement):
self.arrows = arrows
super().__init__(attack, movement)
print(f"attack of attack is:{self.attack}")
print(f"movement of archer is:{self.movement}")
def check_arrows(self):
print(f"No. of arrows are {self.arrows}")
return f"ARCHER:@F*** U WIZARDS@"
class Bruno(Wizard, Archer):
def __init_(self, name, attack, movement, arrows):
Archer.__init__(self, name, arrows, movement)
Wizard.__init__(self, attack)
gray = Bruno("name", 10, 100, 100)
player1 = User(100, 2010)
wizard1 = Wizard("bon", 10, 100, 20)
n = 100
m = 1000
arch = Archer(10, 100, 20)
print(
f'\n\n\nWIZZY BOY INFO:\n NAME:{wizard1.name}\nAGE: {wizard1.age}\nAttck: {wizard1.attack}\nSpeed: {wizard1.movement}\nWIZZARDS:@F*** YOU ARCHERS@')
print(f"\n\n\nArcher info \n Attack{arch.attack}\nMovement{arch.movement}" + arch.check_arrows())
print(arch.check_arrows())
What I have tried:
this is my first time trying multiple inheritance..the code was running fine before i added class bruno