| | |
| | | curPlayer.SetEquipShowSwitch(updEquipShowSwitch)
|
| | | return
|
| | |
|
| | | def GetPlayerMaxEquipClassLV(curPlayer):
|
| | | ## 获取玩家当前解锁的装备阶
|
| | | key = "RealmEquipClassLVMap"
|
| | | RealmEquipClassLVMap = IpyGameDataPY.GetConfigEx(key)
|
| | | if not RealmEquipClassLVMap:
|
| | | RealmEquipClassLVMap = {}
|
| | | infoDict = {}
|
| | | ipyDataMgr = IpyGameDataPY.IPY_Data()
|
| | | for index in xrange(ipyDataMgr.GetEquipControlCount()):
|
| | | ipyData = ipyDataMgr.GetEquipControlByIndex(index)
|
| | | infoDict[ipyData.GetNeedRealmLV()] = ipyData.GetClassLV()
|
| | | needReamlLVList = infoDict.keys()
|
| | | needReamlLVList.sort() # 升序排
|
| | | for i, realmLV in enumerate(needReamlLVList):
|
| | | classLV = infoDict[realmLV]
|
| | | if i == len(needReamlLVList) - 1:
|
| | | RealmEquipClassLVMap[realmLV] = classLV
|
| | | if i == 0:
|
| | | continue
|
| | | else:
|
| | | preRealmLV = needReamlLVList[i - 1]
|
| | | preClassLV = infoDict[preRealmLV]
|
| | | for pRealmLV in range(preRealmLV, realmLV):
|
| | | RealmEquipClassLVMap[pRealmLV] = preClassLV
|
| | | GameWorld.DebugLog("加载境界对应开放最大装备阶设置: %s" % RealmEquipClassLVMap)
|
| | | IpyGameDataPY.SetConfigEx(key, RealmEquipClassLVMap)
|
| | | |
| | | playerRealmLV = curPlayer.GetOfficialRank()
|
| | | if playerRealmLV in RealmEquipClassLVMap:
|
| | | return RealmEquipClassLVMap[playerRealmLV]
|
| | | |
| | | maxRealmLV = max(RealmEquipClassLVMap)
|
| | | if playerRealmLV >= maxRealmLV:
|
| | | return RealmEquipClassLVMap[maxRealmLV]
|
| | | |
| | | return 0
|
| | |
|
| | | #获取当前是第几套装备外观
|
| | | def GetEquipFacadeClassLV(curPlayer):return curPlayer.GetEquipShowSwitch()%1000/10
|
| | |
|