Esempio n. 1
0
def seeAttrOnEveryTime_func(oldPanel, tooOldFlow=None):
    characterId = CacheContorl.characterData['characterId']
    if oldPanel == 'InScenePanel':
        sceneId = CacheContorl.characterData['character']['0']['Position']
        characterIdList = MapHandle.getSceneCharacterIdList(sceneId)
    else:
        characterIdList = ValueHandle.dictKeysToList(
            CacheContorl.characterData['character'])
    characterIdIndex = characterIdList.index(characterId)
    inputS = []
    seeAttrList = seeAttrInEveryTime_func()
    inputS = inputS + seeAttrList
    askSeeAttr = SeeCharacterAttrPanel.askForSeeAttr()
    inputS = inputS + askSeeAttr
    yrn = GameInit.askfor_All(inputS)
    PyCmd.clr_cmd()
    showAttrHandleData = TextLoading.getTextData(TextLoading.cmdPath,
                                                 'seeAttrPanelHandle')
    characterMax = characterIdList[len(characterIdList) - 1]
    if yrn in showAttrHandleData:
        index = showAttrHandleData.index(yrn)
        index = str(index)
        CacheContorl.panelState['AttrShowHandlePanel'] = index
        seeAttrOnEveryTime_func(oldPanel, tooOldFlow)
    elif yrn in panelList:
        PanelStateHandle.panelStateChange(yrn)
        seeAttrOnEveryTime_func(oldPanel, tooOldFlow)
    elif yrn == '0':
        if characterIdIndex == 0:
            CacheContorl.characterData['characterId'] = characterMax
            seeAttrOnEveryTime_func(oldPanel, tooOldFlow)
        else:
            characterId = characterIdList[characterIdIndex - 1]
            CacheContorl.characterData['characterId'] = characterId
            seeAttrOnEveryTime_func(oldPanel, tooOldFlow)
    elif yrn == '1':
        from script.Flow import Main, SeeCharacterList, InScene
        if oldPanel == 'MainFramePanel':
            SeeCharacterAttrPanel.initShowAttrPanelList()
            CacheContorl.characterData['characterId'] = '0'
            Main.mainFrame_func()
        elif oldPanel == 'SeeCharacterListPanel':
            characterListShow = int(GameConfig.characterlist_show)
            nowPageId = characterIdIndex / characterListShow
            CacheContorl.panelState['SeeCharacterListPanel'] = nowPageId
            SeeCharacterAttrPanel.initShowAttrPanelList()
            SeeCharacterList.seeCharacterList_func(tooOldFlow)
        elif oldPanel == 'InScenePanel':
            SeeCharacterAttrPanel.initShowAttrPanelList()
            CacheContorl.characterData['characterId'] = '0'
            InScene.getInScene_func()
    elif yrn == '2':
        if characterId == characterMax:
            characterId = characterIdList[0]
            CacheContorl.characterData['characterId'] = characterId
            seeAttrOnEveryTime_func(oldPanel, tooOldFlow)
        else:
            characterId = characterIdList[characterIdIndex + 1]
            CacheContorl.characterData['characterId'] = characterId
            seeAttrOnEveryTime_func(oldPanel, tooOldFlow)
Esempio n. 2
0
def seeMovePathPanel():
    inputS = []
    nowScene = CacheContorl.characterData['character']['0']['Position']
    nowMap = CacheContorl.nowMap
    nowMapStr = MapHandle.getMapSystemPathStrForList(nowMap)
    mapData = CacheContorl.mapData[nowMapStr]
    movePathInfo = TextLoading.getTextData(TextLoading.messagePath, '27')
    EraPrint.p(movePathInfo)
    EraPrint.p('\n')
    pathEdge = mapData['PathEdge']
    mapSceneId = str(MapHandle.getMapSceneIdForScenePath(nowMap, nowScene))
    scenePath = pathEdge[mapSceneId]
    scenePathList = ValueHandle.dictKeysToList(scenePath)
    try:
        scenePathList.remove(mapSceneId)
    except ValueError:
        pass
    if len(scenePathList) > 0:
        sceneCmd = []
        for scene in scenePathList:
            loadSceneData = MapHandle.getSceneDataForMap(nowMap, scene)
            sceneName = loadSceneData['SceneName']
            sceneCmd.append(sceneName)
        yrn = CmdButtonQueue.optionstr(cmdList=None,
                                       cmdListData=sceneCmd,
                                       cmdColumn=4,
                                       askfor=False,
                                       cmdSize='center')
        inputS = inputS + yrn
    else:
        errorMoveText = TextLoading.getTextData(TextLoading.messagePath, '28')
        EraPrint.p(errorMoveText)
    EraPrint.pline()
    return {'inputS': inputS, 'scenePathList': scenePathList}
Esempio n. 3
0
def detailedSetting_func3():
    flowReturn = CreatorCharacterPanel.detailedSetting3Panel()
    sexTemDataList = ValueHandle.dictKeysToList(TextLoading.getTextData(TextLoading.attrTemplatePath,'SexExperience'))
    sexTemDataList = ValueHandle.reverseArrayList(sexTemDataList)
    sexTemName = sexTemDataList[flowReturn]
    if flowReturn != len(sexTemDataList) - 1:
        CacheContorl.featuresList['Chastity'] = ''
    else:
        pass
    characterSexExperienceData = AttrCalculation.getSexExperience(sexTemName)
    CacheContorl.temporaryCharacter['SexExperience'] = characterSexExperienceData
    CacheContorl.temporaryCharacter['SexGrade'] = AttrCalculation.getSexGrade(characterSexExperienceData)
    PyCmd.clr_cmd()
    detailedSetting_func4()
Esempio n. 4
0
def detailedSetting_func8():
    flowReturn = CreatorCharacterPanel.detailedSetting8Panel()
    weightTemData = TextLoading.getTextData(TextLoading.attrTemplatePath,'WeightTem')
    weightTemList = ValueHandle.dictKeysToList(weightTemData)
    weightTem = weightTemList[int(flowReturn)]
    characterHeight = CacheContorl.temporaryCharacter['Height']
    characterBmi = AttrCalculation.getBMI(weightTem)
    characterWeight = AttrCalculation.getWeight(characterBmi, characterHeight['NowHeight'])
    characterSex = CacheContorl.temporaryCharacter['Sex']
    characterBodyFat = AttrCalculation.getBodyFat(characterSex,weightTem)
    characterMeasurements = AttrCalculation.getMeasurements(characterSex, characterHeight['NowHeight'], characterWeight,characterBodyFat,weightTem)
    CacheContorl.temporaryCharacter['Weight'] = characterWeight
    CacheContorl.temporaryCharacter['BodyFat'] = characterBodyFat
    CacheContorl.temporaryCharacter['Measurements'] = characterMeasurements
    SeeCharacterAttr.acknowledgmentAttribute_func()
Esempio n. 5
0
def getCharacterIdList():
    characterData = CacheContorl.characterData['character']
    characterList = ValueHandle.dictKeysToList(characterData)
    return characterList
Esempio n. 6
0
def getFontDataList():
    FontPath = os.path.join(gamepath, 'data', 'FontConfig.json')
    FontData = GameData._loadjson(FontPath)
    fontList = ValueHandle.dictKeysToList(FontData)
    return fontList