def loadSave_func(oldPanel): inputS = [] savePage = savePageIndex() showSaveValue = savePage[0] lastSavePageValue = savePage[1] SaveHandleFramePanel.loadSaveInfoHeadPanel() flowReturn = SaveHandleFramePanel.seeSaveListPanel(showSaveValue, lastSavePageValue, True) inputS = inputS + flowReturn startId = len(inputS) flowReturn = SaveHandleFramePanel.askForChangeSavePagePanel(startId) inputS = inputS + flowReturn yrn = GameInit.askfor_Int(inputS) PyCmd.clr_cmd() if yrn == str(startId): savePanelPage = int(CacheContorl.panelState['SeeSaveListPanel']) if savePanelPage == 0: CacheContorl.panelState[ 'SeeSaveListPanel'] = CacheContorl.maxSavePage else: CacheContorl.panelState['SeeSaveListPanel'] = savePanelPage - 1 loadSave_func(oldPanel) elif yrn == str(startId + 1): if oldPanel == 'MainFlowPanel': CacheContorl.wframeMouse['wFrameRePrint'] = 1 CacheContorl.panelState['SeeSaveListPanel'] = 0 import script.Design.StartFlow as mainflow mainflow.main_func() elif oldPanel == 'MainFramePanel': CacheContorl.panelState['SeeSaveListPanel'] = 0 import script.Flow.Main as mainframe mainframe.mainFrame_func() pass elif yrn == str(startId + 2): savePanelPage = int(CacheContorl.panelState['SeeSaveListPanel']) if savePanelPage == CacheContorl.maxSavePage: CacheContorl.panelState['SeeSaveListPanel'] = 0 else: CacheContorl.panelState['SeeSaveListPanel'] = savePanelPage + 1 loadSave_func(oldPanel) else: ansReturn = int(yrn) saveId = SaveHandle.getSavePageSaveId(showSaveValue, ansReturn) askForLoadSave_func(oldPanel, saveId)
def loadSave_func(): ''' 绘制读取存档界面流程 ''' while (True): inputS = [] savePage = savePageIndex() showSaveValue = savePage[0] lastSavePageValue = savePage[1] SaveHandleFramePanel.loadSaveInfoHeadPanel() flowReturn = SaveHandleFramePanel.seeSaveListPanel( showSaveValue, lastSavePageValue, True) inputS = inputS + flowReturn startId = len(inputS) flowReturn = SaveHandleFramePanel.askForChangeSavePagePanel(startId) inputS = inputS + flowReturn yrn = GameInit.askfor_Int(inputS) PyCmd.clr_cmd() if yrn == str(startId): savePanelPage = int(CacheContorl.panelState['SeeSaveListPanel']) if savePanelPage == 0: CacheContorl.panelState[ 'SeeSaveListPanel'] = CacheContorl.maxSavePage else: CacheContorl.panelState['SeeSaveListPanel'] = savePanelPage - 1 elif yrn == str(startId + 1): CacheContorl.panelState['SeeSaveListPanel'] = 0 CacheContorl.nowFlowId = CacheContorl.oldFlowId break elif yrn == str(startId + 2): savePanelPage = int(CacheContorl.panelState['SeeSaveListPanel']) if savePanelPage == CacheContorl.maxSavePage: CacheContorl.panelState['SeeSaveListPanel'] = 0 else: CacheContorl.panelState['SeeSaveListPanel'] = savePanelPage + 1 else: ansReturn = int(yrn) saveId = SaveHandle.getSavePageSaveId(showSaveValue, ansReturn) if askForLoadSave_func(saveId): break