def seePlayerListPanel(maxPage):
    titleText = TextLoading.getTextData(TextLoading.stageWordId, '74')
    EraPrint.plt(titleText)
    inputS = []
    pageId = int(CacheContorl.panelState['SeePlayerListPanel'])
    pageShow = int(GameConfig.playerlist_show)
    maxPage = int(maxPage)
    playerMax = CharacterHandle.getCharacterIndexMax()
    if pageId == maxPage:
        showPageStart = pageShow * (pageId)
        showPageOver = showPageStart + (playerMax - showPageStart)
    else:
        showPageOver = pageShow * pageId
        showPageStart = showPageOver - pageShow
    for i in range(showPageStart, showPageOver + 1):
        playerId = str(i)
        cmdId = i - showPageStart
        cmdIdText = CmdButtonQueue.idIndex(cmdId)
        cmdText = AttrText.getPlayerAbbreviationsInfo(playerId)
        cmdIdTextIndex = TextHandle.getTextIndex(cmdIdText)
        windowWidth = int(GameConfig.text_width)
        textWidth = windowWidth - cmdIdTextIndex
        cmdText = TextHandle.align(cmdText, 'center', textWidth=textWidth)
        cmdText = cmdIdText + ' ' + cmdText
        cmdId = str(cmdId)
        EraPrint.plittleline()
        PyCmd.pcmd(cmdText, cmdId, None)
        inputS.append(cmdId)
        EraPrint.p('\n')
    pageText = '(' + str(pageId) + '/' + str(maxPage) + ')'
    EraPrint.printPageLine(sample='-', string=pageText)
    EraPrint.p('\n')
    return inputS
Beispiel #2
0
def seePlayerEquipmentPanel(playerId):
    EraPrint.plittleline()
    EraPrint.p(TextLoading.getTextData(TextLoading.stageWordId, '37'))
    panelState = CacheContorl.panelState['PlayerEquipmentPanel']
    if panelState == "0":
        PyCmd.pcmd(panelStateOffText, 'PlayerEquipmentPanel')
        playerData = AttrHandle.getAttrData(playerId)
        EraPrint.p('\n')
        EraPrint.p(TextLoading.getTextData(TextLoading.stageWordId, '39'))
        EraPrint.p('\n')
        playerClothingList = playerData['Clothing']
        playerClothingText = AttrText.getClothingText(playerClothingList)
        EraPrint.plist(playerClothingText, 4, 'center')
        EraPrint.p('\n')
        EraPrint.p(TextLoading.getTextData(TextLoading.stageWordId, '40'))
        EraPrint.p('\n')
        playerSexItemList = playerData['SexItem']
        playerSexItemText = AttrText.getSexItemText(playerSexItemList)
        EraPrint.plist(playerSexItemText, 5, 'center')
        return 'PlayerEquipmentPanel'
    else:
        PyCmd.pcmd(panelStateOnText, 'PlayerEquipmentPanel', None)
        EraPrint.p('\n')
        return 'PlayerEquipmentPanel'
Beispiel #3
0
def seePlayerEngravingPanel(playerId):
    EraPrint.plittleline()
    EraPrint.p(TextLoading.getTextData(TextLoading.stageWordId, '7'))
    panelState = CacheContorl.panelState['PlayerEngravingPanel']
    if panelState == "0":
        PyCmd.pcmd(panelStateOffText, 'PlayerEngravingPanel')
        EraPrint.p('\n')
        playerData = AttrHandle.getAttrData(playerId)
        playerEngraving = playerData['Engraving']
        playerEngravingText = AttrText.getEngravingText(playerEngraving)
        EraPrint.plist(playerEngravingText, 3, 'center')
        return 'PlayerEngravingPanel'
    else:
        PyCmd.pcmd(panelStateOnText, 'PlayerEngravingPanel')
        EraPrint.p('\n')
        return 'PlayerEngravingPanel'
Beispiel #4
0
def seePlayerFeaturesPanel(playerId):
    EraPrint.plittleline()
    EraPrint.p(TextLoading.getTextData(TextLoading.stageWordId, '6'))
    panelState = CacheContorl.panelState['PlayerFeaturesPanel']
    if panelState == "0":
        PyCmd.pcmd(panelStateOffText, 'PlayerFeaturesPanel')
        EraPrint.p('\n')
        playerData = AttrHandle.getAttrData(playerId)
        playerFeatures = playerData['Features']
        playerFeaturesStr = AttrText.getFeaturesStr(playerFeatures)
        EraPrint.p(playerFeaturesStr)
        return 'PlayerFeaturesPanel'
    else:
        PyCmd.pcmd(panelStateOnText, 'PlayerFeaturesPanel')
        EraPrint.p('\n')
        return 'PlayerFeaturesPanel'
    pass
Beispiel #5
0
def seePlayerExperiencePanel(playerId):
    EraPrint.plittleline()
    EraPrint.p(TextLoading.getTextData(TextLoading.stageWordId, '18'))
    panelState = CacheContorl.panelState['PlayerExperiencePanel']
    if panelState == "0":
        PyCmd.pcmd(panelStateOffText, 'PlayerExperiencePanel')
        playerData = AttrHandle.getAttrData(playerId)
        EraPrint.p('\n')
        playerSexExperienceList = playerData['SexExperience']
        playerSex = CacheContorl.playObject['object'][playerId]['Sex']
        playerSexTextList = AttrText.getSexExperienceText(
            playerSexExperienceList, playerSex)
        EraPrint.plist(playerSexTextList, 4, 'center')
        return 'PlayerExperiencePanel'
    else:
        PyCmd.pcmd(panelStateOnText, 'PlayerExperiencePanel')
        EraPrint.p('\n')
        return 'PlayerExperiencePanel'
Beispiel #6
0
def mainFramePanel():
    cmdList = []
    playerId = CacheContorl.playObject['objectId']
    playerData = AttrHandle.getAttrData(playerId)
    titleText = TextLoading.getTextData(TextLoading.stageWordId, '64')
    EraPrint.plt(titleText)
    dateText = GameTime.getDateText()
    EraPrint.p(dateText)
    EraPrint.p(' ')
    weekDateText = GameTime.getWeekDayText()
    EraPrint.p(weekDateText)
    EraPrint.p(' ')
    playerName = playerData['Name']
    PyCmd.pcmd(playerName, playerName, None)
    cmdList.append(playerName)
    EraPrint.p(' ')
    goldText = AttrText.getGoldText(playerId)
    EraPrint.p(goldText)
    EraPrint.p('\n')
    AttrPrint.printHpAndMpBar(playerId)
    mainMenuText = TextLoading.getTextData(TextLoading.stageWordId, '68')
    EraPrint.sontitleprint(mainMenuText)
    EraPrint.p('\n')
    askForMainMenu = CmdButtonQueue.optionint(CmdButtonQueue.mainmenu,
                                              4,
                                              'left',
                                              askfor=False,
                                              cmdSize='center')
    cmdList = cmdList + askForMainMenu
    systemMenuText = TextLoading.getTextData(TextLoading.stageWordId, '69')
    EraPrint.sontitleprint(systemMenuText)
    EraPrint.p('\n')
    systemMenuStartId = len(askForMainMenu)
    askForSystemMenu = CmdButtonQueue.optionint(CmdButtonQueue.systemmenu,
                                                4,
                                                'left',
                                                askfor=False,
                                                cmdSize='center',
                                                startId=systemMenuStartId)
    cmdList = cmdList + askForSystemMenu
    return cmdList
def seePlayerWearClothes(playerId):
    sceneInfo = TextLoading.getTextData(TextLoading.stageWordId,'79')
    EraPrint.plt(sceneInfo)
    playerInfo = AttrText.getPlayerAbbreviationsInfo(playerId)
    EraPrint.p(playerInfo)