| | |
| | | import PlayerHero
|
| | | import ShareDefine
|
| | | import IpyGameDataPY
|
| | | import PlayerControl
|
| | | import GameWorld
|
| | | import ChConfig
|
| | |
|
| | |
| | | GameWorld.DebugAnswer(curPlayer, "武将升星: Hero s 背包位置 升x星")
|
| | | GameWorld.DebugAnswer(curPlayer, "武将突破: Hero b 背包位置 设置等级")
|
| | | GameWorld.DebugAnswer(curPlayer, "武将觉醒: Hero a 背包位置 设置等级")
|
| | | GameWorld.DebugAnswer(curPlayer, "武将图鉴: Hero t 武将ID 是否激活")
|
| | | GameWorld.DebugAnswer(curPlayer, "武将图鉴: Hero t 武将ID 图鉴星级 图鉴突破等级")
|
| | | GameWorld.DebugAnswer(curPlayer, "重置图鉴: Hero t 0")
|
| | | GameWorld.DebugAnswer(curPlayer, "武将皮肤: Hero sk 武将ID 皮肤索引 是否解锁")
|
| | | GameWorld.DebugAnswer(curPlayer, "清空武将: ClearPack 35")
|
| | |
| | |
|
| | | # 图鉴
|
| | | if value == "t":
|
| | | isAct = 0
|
| | | if not value2:
|
| | | heroIDList = []
|
| | | ipyDataMgr = IpyGameDataPY.IPY_Data()
|
| | |
| | | ipyData = ipyDataMgr.GetHeroByIndex(index)
|
| | | heroIDList.append(ipyData.GetHeroID())
|
| | | else:
|
| | | isAct = msgList[2] if len(msgList) > 2 else 0
|
| | | heroIDList = [value2]
|
| | | |
| | | syncHeroIDList = []
|
| | | for heroID in heroIDList:
|
| | | heroIpyData = IpyGameDataPY.GetIpyGameData("Hero", heroID)
|
| | | if not heroIpyData:
|
| | | continue
|
| | | heroIndex = heroIpyData.GetHeroIndex()
|
| | | if GameWorld.GetDictValueByBit(curPlayer, ChConfig.Def_PDict_HeroActState, heroIndex) == isAct:
|
| | | continue
|
| | | GameWorld.SetDictValueByBit(curPlayer, ChConfig.Def_PDict_HeroActState, heroIndex, isAct)
|
| | | syncHeroIDList.append(heroID)
|
| | |
|
| | | PlayerHero.Sync_HeroInfo(curPlayer, syncHeroIDList)
|
| | | if not value2:
|
| | | if value2 == 0:
|
| | | syncHeroIDList = []
|
| | | for heroID in heroIDList:
|
| | | if not curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_HeroBook % heroID):
|
| | | continue
|
| | | syncHeroIDList.append(heroID)
|
| | | PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_HeroBook % heroID, 0)
|
| | | GameWorld.DebugAnswer(curPlayer, "重置图鉴OK!")
|
| | | else:
|
| | | GameWorld.DebugAnswer(curPlayer, "设置武将(%s),激活(%s)" % (value2, isAct))
|
| | | heroID = value2
|
| | | syncHeroIDList = [heroID]
|
| | | bookStarLV = msgList[2] if len(msgList) > 2 else 0
|
| | | bookBreakLV = msgList[3] if len(msgList) > 3 else 0
|
| | | if (bookStarLV or bookStarLV) and not PlayerHero.GetHeroBookInitState(curPlayer, heroID):
|
| | | PlayerHero.SetHeroBookInitState(curPlayer, heroID, 1)
|
| | | PlayerHero.SetHeroBookStarLV(curPlayer, heroID, bookStarLV)
|
| | | PlayerHero.SetHeroBookBreakLV(curPlayer, heroID, bookBreakLV)
|
| | | GameWorld.DebugAnswer(curPlayer, "设置武将(%s)图鉴星级(%s),突破(%s)" % (heroID, bookStarLV, bookBreakLV))
|
| | | |
| | | PlayerHero.Sync_HeroInfo(curPlayer, syncHeroIDList)
|
| | | return
|
| | |
|
| | | # 皮肤
|