Commit 0fc57075 by BellCodeEditor

auto save

parent a840fb96
Showing with 4 additions and 3 deletions
import random
class Hero(object): class Hero(object):
def __init__(self, name): # 实例属性 def __init__(self, name): # 实例属性
self.name = name self.name = name
...@@ -41,12 +42,12 @@ class Player(Hero): # 玩家英雄 ...@@ -41,12 +42,12 @@ class Player(Hero): # 玩家英雄
houyi=Player("houyi","射手") houyi=Player("houyi","射手")
yase = Hero("垭瑟") yase = Hero("垭瑟")
print("-"*30) print("-" * 30)
print(" 战斗开始") print(" 战斗开始")
while tuple: while tuple:
print("-"*30) print("-" * 30)
choie = input("请选择计能 1/2") choie = input("请选择计能 1/2")
if choice == "q": if choie == "q":
print("游戏结束") print("游戏结束")
break break
elif choie == "1": elif choie == "1":
......
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