| | |
| | | #Operate_EquipWash.OnEquipWashLogin(curPlayer)
|
| | | #装备位宝石镶嵌通知
|
| | | #Operate_EquipStone.OnLogin(curPlayer)
|
| | | if not GameWorld.GetDictValueByBit(curPlayer, ChConfig.Def_Player_Dict_VersionFix, ChConfig.Def_VerFix_LingGenShow):
|
| | | GameWorld.SetDictValueByBit(curPlayer, ChConfig.Def_Player_Dict_VersionFix, ChConfig.Def_VerFix_LingGenShow, 1)
|
| | | ChangeEquipfacadeByLingGen(curPlayer)
|
| | | # if not GameWorld.GetDictValueByBit(curPlayer, ChConfig.Def_Player_Dict_VersionFix, ChConfig.Def_VerFix_LingGenShow):
|
| | | # GameWorld.SetDictValueByBit(curPlayer, ChConfig.Def_Player_Dict_VersionFix, ChConfig.Def_VerFix_LingGenShow, 1)
|
| | | # ChangeEquipfacadeByLingGen(curPlayer)
|
| | |
|
| | | ePartStarLVPack = ChPyNetSendPack.tagMCEquipPartStarInfo() # A3 B1 装备部位星数信息 #tagMCEquipPartStarInfo
|
| | | ePartPlusLVPack = ChPyNetSendPack.tagMCEquipPartPlusInfo() # A3 B3 装备部位强化信息 #tagMCEquipPartPlusInfo
|
| | |
| | | if oldEquipShowSwitch == updEquipShowSwitch:
|
| | | return
|
| | | curPlayer.SetEquipShowSwitch(updEquipShowSwitch)
|
| | | ChangeEquipEffectByPlusMaster(curPlayer, classLV)
|
| | | return True
|
| | |
|
| | | #!!! 特效根据灵根品级变化改成根据强化大师变化
|
| | | def ChangeEquipfacadeByLingGen(curPlayer):
|
| | | ## 灵根品级变化影响角色外观显示 灵根特效表key * 1000+第几套*10+是否有套装
|
| | | pointValueInfo = [[ShareDefine.Def_Effect_Metal,PlayerControl.GetMetalQualityLV(curPlayer)],
|
| | | [ShareDefine.Def_Effect_Wood,PlayerControl.GetWoodQualityLV(curPlayer)],
|
| | | [ShareDefine.Def_Effect_Water,PlayerControl.GetWaterQualityLV(curPlayer)],
|
| | | [ShareDefine.Def_Effect_Fire,PlayerControl.GetFireQualityLV(curPlayer)],
|
| | | [ShareDefine.Def_Effect_Earth,PlayerControl.GetEarthQualityLV(curPlayer)],
|
| | | ]
|
| | | g_skillElementCntDict = {} #灵根对应使用专精技能数量
|
| | | skillManager = curPlayer.GetSkillManager()
|
| | | gameData = GameWorld.GetGameData()
|
| | | for i in xrange(skillManager.GetSkillCount()):
|
| | | curSkill = skillManager.GetSkillByIndex(i)
|
| | | skillID = curSkill.GetSkillTypeID()
|
| | | curSelectSkillID = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_SkillElementID % skillID)
|
| | | if not curSelectSkillID:
|
| | | continue
|
| | | elementSkillData = gameData.GetSkillBySkillID(curSelectSkillID)
|
| | | if not elementSkillData:
|
| | | continue
|
| | | skillElementType = SkillShell.GetSkillElementType(elementSkillData)
|
| | | g_skillElementCntDict[skillElementType] = g_skillElementCntDict.get(skillElementType, 0) + 1
|
| | | # ## 灵根品级变化影响角色外观显示 灵根特效表key * 1000+第几套*10+是否有套装
|
| | | # pointValueInfo = [[ShareDefine.Def_Effect_Metal,PlayerControl.GetMetalQualityLV(curPlayer)],
|
| | | # [ShareDefine.Def_Effect_Wood,PlayerControl.GetWoodQualityLV(curPlayer)],
|
| | | # [ShareDefine.Def_Effect_Water,PlayerControl.GetWaterQualityLV(curPlayer)],
|
| | | # [ShareDefine.Def_Effect_Fire,PlayerControl.GetFireQualityLV(curPlayer)],
|
| | | # [ShareDefine.Def_Effect_Earth,PlayerControl.GetEarthQualityLV(curPlayer)],
|
| | | # ]
|
| | | # g_skillElementCntDict = {} #灵根对应使用专精技能数量
|
| | | # skillManager = curPlayer.GetSkillManager()
|
| | | # gameData = GameWorld.GetGameData()
|
| | | # for i in xrange(skillManager.GetSkillCount()):
|
| | | # curSkill = skillManager.GetSkillByIndex(i)
|
| | | # skillID = curSkill.GetSkillTypeID()
|
| | | # curSelectSkillID = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_SkillElementID % skillID)
|
| | | # if not curSelectSkillID:
|
| | | # continue
|
| | | # elementSkillData = gameData.GetSkillBySkillID(curSelectSkillID)
|
| | | # if not elementSkillData:
|
| | | # continue
|
| | | # skillElementType = SkillShell.GetSkillElementType(elementSkillData)
|
| | | # g_skillElementCntDict[skillElementType] = g_skillElementCntDict.get(skillElementType, 0) + 1
|
| | | # |
| | | # showPointID, showQualityLV = 0, 0
|
| | | # for pointID, qualityLV in pointValueInfo:
|
| | | # if qualityLV > showQualityLV:
|
| | | # showQualityLV = qualityLV
|
| | | # showPointID = pointID
|
| | | # elif showQualityLV and qualityLV == showQualityLV:
|
| | | # #比谁的专精技能数量多
|
| | | # if g_skillElementCntDict.get(pointID, 0) > g_skillElementCntDict.get(showPointID, 0):
|
| | | # showQualityLV = qualityLV
|
| | | # showPointID = pointID
|
| | | # effectID = 0
|
| | | # if showPointID:
|
| | | # ipyData = IpyGameDataPY.GetIpyGameData('LingGenEffect', showPointID, showQualityLV)
|
| | | # if not ipyData:
|
| | | # return
|
| | | # effectID = ipyData.GetID()
|
| | | # oldEquipShowSwitch = curPlayer.GetEquipShowSwitch()
|
| | | # updEquipShowSwitch = oldEquipShowSwitch % 1000 + oldEquipShowSwitch / 1000000 * 1000000+ 1000 * effectID
|
| | | # GameWorld.DebugLog('灵根品级变化影响角色外观显示g_skillElementCntDict=%s,oldEquipShowSwitch=%s,updEquipShowSwitch=%s'%
|
| | | # (g_skillElementCntDict, oldEquipShowSwitch, updEquipShowSwitch))
|
| | | # if oldEquipShowSwitch != updEquipShowSwitch:
|
| | | # curPlayer.SetEquipShowSwitch(updEquipShowSwitch)
|
| | | return
|
| | | def ChangeEquipEffectByPlusMaster(curPlayer, classLV):
|
| | | # 强化大师特效
|
| | | if (classLV != GetEquipFacadeClassLV(curPlayer)):
|
| | | return
|
| | |
|
| | | showPointID, showQualityLV = 0, 0
|
| | | for pointID, qualityLV in pointValueInfo:
|
| | | if qualityLV > showQualityLV:
|
| | | showQualityLV = qualityLV
|
| | | showPointID = pointID
|
| | | elif showQualityLV and qualityLV == showQualityLV:
|
| | | #比谁的专精技能数量多
|
| | | if g_skillElementCntDict.get(pointID, 0) > g_skillElementCntDict.get(showPointID, 0):
|
| | | showQualityLV = qualityLV
|
| | | showPointID = pointID
|
| | | effectID = 0
|
| | | if showPointID:
|
| | | ipyData = IpyGameDataPY.GetIpyGameData('LingGenEffect', showPointID, showQualityLV)
|
| | | if not ipyData:
|
| | | return
|
| | | effectID = ipyData.GetID()
|
| | | masterPlusLV = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_EquipPartMasterPlusLV % classLV)
|
| | | ## 强化大师影响角色外观显示 强化大师等级 * 1000+第几套*10+是否有套装
|
| | | oldEquipShowSwitch = curPlayer.GetEquipShowSwitch()
|
| | | updEquipShowSwitch = oldEquipShowSwitch % 1000 + oldEquipShowSwitch / 1000000 * 1000000+ 1000 * effectID
|
| | | GameWorld.DebugLog('灵根品级变化影响角色外观显示g_skillElementCntDict=%s,oldEquipShowSwitch=%s,updEquipShowSwitch=%s'%
|
| | | (g_skillElementCntDict, oldEquipShowSwitch, updEquipShowSwitch))
|
| | | updEquipShowSwitch = oldEquipShowSwitch % 1000 + oldEquipShowSwitch / 1000000 * 1000000+ 1000 * masterPlusLV
|
| | | GameWorld.DebugLog('强化大师影变化影响角色外观显示,oldEquipShowSwitch=%s,updEquipShowSwitch=%s'%
|
| | | (oldEquipShowSwitch, updEquipShowSwitch))
|
| | | if oldEquipShowSwitch != updEquipShowSwitch:
|
| | | curPlayer.SetEquipShowSwitch(updEquipShowSwitch)
|
| | | return
|
| | |
|
| | |
|
| | | def ChangeEquipfacadeByHorsePetSkin(curPlayer, skinType, skinIndex):
|
| | | ##骑宠觉醒外观变更 灵宠外观索引*10000000+坐骑外观索引*1000000+灵根特效表key * 1000+第几套*10+是否有套装
|
| | | oldEquipShowSwitch = curPlayer.GetEquipShowSwitch()
|