Commit f4291f08 by BellCodeEditor

save project

parent fbd53b39
Showing with 3 additions and 2 deletions
import random
class Hero(object): class Hero(object):
def __init__(self, name): def __init__(self, name):
self.name = name self.name = name
...@@ -45,7 +46,7 @@ while True: ...@@ -45,7 +46,7 @@ while True:
a=input('请选择技能:1攻击/2治疗') a=input('请选择技能:1攻击/2治疗')
if int(a)==1: if int(a)==1:
houyi.combat(yase) houyi.combat(yase)
elif int(a)==2 elif int(a)==2:
houyi.cure() houyi.cure()
elif a=="q": elif a=="q":
print('游戏结束') print('游戏结束')
...@@ -53,7 +54,7 @@ while True: ...@@ -53,7 +54,7 @@ while True:
else: else:
print("重输") print("重输")
continue continue
b=randon.randint(1,3) b=random.randint(1,3)
if b==3: if b==3:
yase.cure() yase.cure()
else: else:
......
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