Python代码求调整(自己的项目)
  • 板块灌水区
  • 楼主mmnBilibili
  • 当前回复4
  • 已保存回复4
  • 发布时间2024/9/17 21:17
  • 上次更新2024/9/18 12:43:43
查看原帖
Python代码求调整(自己的项目)
1341011
mmnBilibili楼主2024/9/17 21:17

求dalao帮我调一下这个Python,自己的项目,但是什么都不输出,好像是报错,求调(玄关

import time
import random

def debug():
    #only to debug
    print('''\tWelcome to the Danger and Player's Fight!
    This code made in MuMunian,China.
    Bilibili:G18C's MuMunian.
    You can input something to order this code.
    Have a good time!\n''')
    print("2024:09:16:21:17\n\tToday this code is new!\n\n")

class playing:
    #not dec
    playerLife=0
    dangerLife=0
    floor=0

Run=True
get=input("\n\tInput to continue...\n")
playerName=""
helpstring="\n\tThe help don't finish.\n"

#exit function
def ifexit(getstring):
    if getstring=="exit":
        Run=False
        return True
    return False

#help function
def ifhelp(getstring):
    if getstring=="help":
        print(helpstring)

# debug()

print("Do you want to in the debug?")
get=str(input())
if(get=="yes"):
    debug()

while(Run):
    get=str(input("What do you want to do?\n"))
    if ifexit(get):
        break
    ifhelp(get)

print("\nThanks to play our game!\n")
2024/9/17 21:17
加载中...