Esempio n. 1
0
def acknowledgmentAttributeAns(inputList):
    characterId = CacheContorl.characterData['characterId']
    yrn = GameInit.askfor_All(inputList)
    showAttrHandleData = TextLoading.getTextData(TextLoading.cmdPath,
                                                 'seeAttrPanelHandle')
    PyCmd.clr_cmd()
    if yrn in panelList:
        PanelStateHandle.panelStateChange(yrn)
        acknowledgmentAttribute_func()
    elif yrn == '0':
        GameTime.initTime()
        AttrCalculation.setAttrOver(characterId)
        CharacterHandle.initCharacterList()
        SeeCharacterAttrPanel.initShowAttrPanelList()
        characterPosition = CacheContorl.characterData['character'][
            characterId]['Position']
        MapHandle.characterMoveScene(['0'], characterPosition, characterId)
        from script.Flow import Main
        Main.mainFrame_func()
    elif yrn == '1':
        CacheContorl.wframeMouse['wFrameRePrint'] = 1
        EraPrint.pnextscreen()
        SeeCharacterAttrPanel.initShowAttrPanelList()
        from script.Design import StartFlow
        StartFlow.main_func()
    elif yrn in showAttrHandleData:
        index = showAttrHandleData.index(yrn)
        index = str(index)
        CacheContorl.panelState['AttrShowHandlePanel'] = index
        acknowledgmentAttribute_func()
Esempio n. 2
0
def initCharacterPosition():
    '''
    初始化角色位置
    '''
    for character in CacheContorl.characterData['character']:
        characterPosition = CacheContorl.characterData['character'][character].Position
        characterDormitory = CacheContorl.characterData['character'][character].Dormitory
        characterDormitory = MapHandle.getMapSystemPathForStr(characterDormitory)
        MapHandle.characterMoveScene(characterPosition,characterDormitory,character)
Esempio n. 3
0
def initGameStart():
    '''
    用于结束角色创建正式开始游戏的初始化流程
    '''
    CharacterHandle.initCharacterDormitory()
    CharacterHandle.initCharacterPosition()
    Course.initPhaseCourseHour()
    Interest.initCharacterInterest()
    Course.initCharacterKnowledge()
    Course.initClassTeacher()
    Course.initClassTimeTable()
    characterPosition = CacheContorl.characterData['character'][0].Position
    MapHandle.characterMoveScene(['0'],characterPosition,0)
    CacheContorl.nowFlowId = 'main'
Esempio n. 4
0
def identicalMapMove(characterId, nowMap, nowMapSceneId, targetMapSceneId):
    movePath = MapHandle.getPathfinding(nowMap, nowMapSceneId,
                                        targetMapSceneId)
    if movePath != 'End' and movePath != 'Null':
        nowTargetSceneId = movePath['Path'][1]
        nowNeedTime = movePath['Time'][1]
        nowCharacterPosition = MapHandle.getScenePathForMapSceneId(
            nowMap, nowMapSceneId)
        nowTargetPosition = MapHandle.getScenePathForMapSceneId(
            nowMap, nowTargetSceneId)
        MapHandle.characterMoveScene(nowCharacterPosition, nowTargetPosition,
                                     characterId)
        GameTime.subTimeNow(nowNeedTime)
    return movePath
Esempio n. 5
0
def initGameStart():
    '''
    用于结束角色创建正式开始游戏的初始化流程
    '''
    GameTime.initTime()
    AttrCalculation.setAttrOver('0')
    Course.initPhaseCourseHour()
    CharacterHandle.initCharacterList()
    Interest.initCharacterInterest()
    Course.initCharacterKnowledge()
    Course.initClassTeacher()
    Course.initClassTimeTable()
    SeeCharacterAttrPanel.initShowAttrPanelList()
    characterPosition = CacheContorl.characterData['character']['0'][
        'Position']
    MapHandle.characterMoveScene(['0'], characterPosition, '0')
    CacheContorl.nowFlowId = 'main'
Esempio n. 6
0
def identicalMapMove(characterId:str,nowMap:list,nowMapSceneId:str,targetMapSceneId:str) -> 'MoveEnd:str_Null,str_End,list':
    '''
    角色在相同地图层级内移动
    Keyword arguments:
    characterId -- 角色id
    nowMap -- 当前地图路径
    nowMapSceneId -- 当前角色所在场景(当前地图层级下的相对坐标)
    targetMapSceneId -- 寻路目标场景(当前地图层级下的相对坐标)
    '''
    nowMapStr = MapHandle.getMapSystemPathStrForList(nowMap)
    movePath = MapHandle.getPathfinding(nowMapStr,nowMapSceneId,targetMapSceneId)
    if movePath != 'End' and movePath != 'Null':
        nowTargetSceneId = movePath['Path'][0]
        nowNeedTime = movePath['Time'][0]
        nowCharacterPosition = MapHandle.getScenePathForMapSceneId(nowMap,nowMapSceneId)
        nowTargetPosition = MapHandle.getScenePathForMapSceneId(nowMap,nowTargetSceneId)
        MapHandle.characterMoveScene(nowCharacterPosition,nowTargetPosition,characterId)
        GameTime.subTimeNow(nowNeedTime)
    return movePath
Esempio n. 7
0
def initGameStart():
    '''
    用于结束角色创建正式开始游戏的初始化流程
    '''
    GameTime.initTime()
    AttrCalculation.setAttrOver('0')
    Course.initPhaseCourseHour()
    CharacterHandle.initCharacterList()
    characterSuit = Clothing.creatorSuit(
        'Uniform', CacheContorl.characterData['character']['0']['Sex'])
    for clothing in characterSuit:
        CacheContorl.characterData['character']['0']['Clothing'][clothing][
            uuid.uuid1()] = characterSuit[clothing]
    Clothing.characterPutOnClothing('0')
    Interest.initCharacterInterest()
    Course.initCharacterKnowledge()
    Course.initClassTeacher()
    Course.initClassTimeTable()
    SeeCharacterAttrPanel.initShowAttrPanelList()
    characterPosition = CacheContorl.characterData['character']['0'][
        'Position']
    MapHandle.characterMoveScene(['0'], characterPosition, '0')
    CacheContorl.nowFlowId = 'main'
Esempio n. 8
0
def initCharacterPositionNow(characterData, characterIdS):
    characterInitPosition = characterData['Position']
    characterPosition = CacheContorl.characterData['character'][characterIdS][
        'Position']
    MapHandle.characterMoveScene(characterPosition, characterInitPosition,
                                 characterIdS)