| | |
| | | if taskType == ChConfig.TaskType_LV:
|
| | | taskValue = curPlayer.GetLV()
|
| | |
|
| | | elif taskType == ChConfig.TaskType_FBPass:
|
| | | if len(conds) != 2:
|
| | | elif taskType == ChConfig.TaskType_MainLevel:
|
| | | if not conds:
|
| | | return 0
|
| | | mapID, lineID = conds
|
| | | mapID = ChConfig.Def_FBMapID_Main
|
| | | lineID = conds[0]
|
| | | taskValue = 1 if FBCommon.IsFBPass(curPlayer, mapID, lineID) else 0
|
| | |
|
| | | elif taskType == ChConfig.TaskType_TreeLV:
|
| | |
| | | elif taskType == ChConfig.TaskType_RealmLV:
|
| | | taskValue = curPlayer.GetOfficialRank()
|
| | |
|
| | | elif taskType == ChConfig.TaskType_EquipColor:
|
| | | if not conds:
|
| | | return 0
|
| | | needColor = conds[0]
|
| | | equipCnt = 0
|
| | | equipPack = curPlayer.GetItemManager().GetPack(IPY_GameWorld.rptEquip)
|
| | | for equipPlace in ChConfig.Def_MainEquipPlaces:
|
| | | equipIndex = equipPlace - 1
|
| | | if equipIndex < 0 or equipIndex >= equipPack.GetCount():
|
| | | continue
|
| | | curEquip = equipPack.GetAt(equipIndex)
|
| | | if not curEquip or curEquip.IsEmpty():
|
| | | continue
|
| | | itemColor = curEquip.GetItemColor()
|
| | | if itemColor >= needColor:
|
| | | equipCnt += 1
|
| | | taskValue = equipCnt
|
| | | |
| | | return taskValue
|
| | |
|
| | | def UpdTaskValue(curPlayer, taskType):
|