Exemplo n.º 1
0
def title_panel():
    """ 绘制游戏标题菜单 """
    clear_screen = panel.ClearScreenPanel()
    clear_screen.draw()
    width = config_normal.text_width
    title_info = panel.TitleAndRightInfoListPanel()
    game_name = config_normal.game_name
    info_list = [
        config_normal.author, config_normal.verson, config_normal.verson_time
    ]
    title_info.set(config_normal.game_name, info_list, width)
    title_info.draw()
    lineFeed = draw.NormalDraw()
    lineFeed.width = 1
    lineFeed.text = "\n"
    info = _("人类是可以被驯化的")
    lineFeed.draw()
    info_draw = draw.CenterDraw()
    info_draw.text = info
    info_draw.width = width
    info_draw.draw()
    lineFeed.draw()
    lineFeed.draw()
    line = draw.LineDraw("=", width)
    line.draw()
    now_list = [_("开始游戏"), _("读取存档"), _("退出游戏")]
    button_panel = panel.OneMessageAndSingleColumnButton()
    button_panel.set(now_list, "", 0)
    button_panel.draw()
    return_list = button_panel.get_return_list()
    ans = flow_handle.askfor_all(return_list.keys())
    py_cmd.clr_cmd()
    now_key = return_list[ans]
    if now_key == now_list[0]:
        cache.now_panel_id = constant.Panel.CREATOR_CHARACTER
    elif now_key == now_list[1]:
        now_panel = see_save_info_panel.SeeSaveListPanel(width, 0)
        now_panel.draw()
    elif now_key == now_list[2]:
        os._exit(0)
Exemplo n.º 2
0
def handle_save():
    """ 处理读写存档指令 """
    now_panel = see_save_info_panel.SeeSaveListPanel(width, 1)
    now_panel.draw()
Exemplo n.º 3
0
 def see_save_handle(self):
     """ 处理读写存档 """
     now_panel = see_save_info_panel.SeeSaveListPanel(self.width, 1)
     now_panel.draw()