Commit 4acdfe80 by BellCodeEditor

auto save

parent e1143c65
Showing with 16 additions and 2 deletions
...@@ -31,4 +31,18 @@ class Player(Hero): ...@@ -31,4 +31,18 @@ class Player(Hero):
print("当前等级、血量、攻击力分别为:",self.level,self.hp,self.attack) print("当前等级、血量、攻击力分别为:",self.level,self.hp,self.attack)
houyi = Player( "后羿", "射手") houyi = Player( "后羿", "射手")
yase = Hero("垭瑟") yase = Hero("垭瑟")
\ No newline at end of file
class Player(Hero):
def __init__(self,name,hero_type):
super(player,name).__init__(name)
self.hp=200
self.attack=50
self.hero_type=hero_type
\ 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