Commit ffeabf1c by BellCodeEditor

save project

parent 8681211d
Showing with 15 additions and 2 deletions
...@@ -17,4 +17,17 @@ class Hero(object): ...@@ -17,4 +17,17 @@ class Hero(object):
exit() exit()
yase = Hero("亚瑟") yase = Hero("亚瑟")
houyi= Hero("后羿") houyi= Hero("后羿")
yase.combat(houyi) yase.combat(houyi)
\ No newline at end of file
class Player(Hero):
def __init__(self,namee):
super().__init__(name)
self.hp = 2000000000000000000000000000000000000000000000000000000000000000000000000
self.attack = 500000000000000000000000000000000000000000000000000000000000000000000000000000000000
player = player("狗哥")
print("玩家的血量",playerm.hp)
print("玩家的伤害",playerm.attack)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment