Commit 63b17f33 by BellCodeEditor

save project

parent 3dc9f116
Showing with 7 additions and 0 deletions
...@@ -19,6 +19,13 @@ class Hero(object): ...@@ -19,6 +19,13 @@ class Hero(object):
info = ninfo1+ info2 + info3 info = ninfo1+ info2 + info3
print(info) print(info)
exit() exit()
def cure(self)
self.hp=self.hp=60
if self.hp=250:
self.hp=250
print(self.name+"加血",60,"現血"+self.hp)
class Player(Hero): class Player(Hero):
def __init__(self,name,hero_type): def __init__(self,name,hero_type):
super(Player,self).__init__(name) super(Player,self).__init__(name)
......
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