示例#1
0
文件: Canvas.py 项目: bmeares/chess
def quit():
    clear()
    print("\n Would you like to save your game? ", end="")
    y = yesNo()
    clear()
    if y:
        utils.writeSave()
    else:
        utils.delete_save()
    sys.exit(0)
示例#2
0
文件: main.py 项目: Astrosp/code_y
def state():

    playing = True

    while playing:
        if (globVar.playerCount % 2) == 0:
            globVar.player = "W"
        else:
            globVar.player = "b"

        Player.turn()
        globVar.playerCount += 1
        # utils.check_king()
        playing = not utils.checkWin()
        utils.clearSave()
        utils.writeSave()

    return playing