Advertisement
Guest User

Untitled

a guest
Jun 25th, 2017
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.59 KB | None | 0 0
  1. class Stats:
  2.     def __init__(self, name, hp, st, mag):
  3.         self.name = name
  4.         self.hp = hp
  5.         self.st = st
  6.         self.mag = mag
  7.  
  8.     def Toon(self):
  9.         print("Name = ", self.name,
  10.             "\nhp = ", self.hp,
  11.             "\nst =", self.st,
  12.             "\nmag =", self.mag, "\n")
  13.  
  14. class Hero(Stats):
  15.  
  16.     def __init__(self, name, hp, st, mag):
  17.         Stats.__init__(self, name, hp, st, mag)
  18.         self.Toon()
  19.  
  20.     def classInfo(self):
  21.         return Stats.Toon(self)
  22.  
  23. a = Hero("Amrasurion", "100", "200", "300")
  24. b = Hero("Bunchies", "111", "222", "333")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement