qinglong task redpoint commit
parent
1243629056
commit
cb69e474b9
|
@ -11,10 +11,11 @@ function this:InitComponent(gameObject)
|
|||
this.gameObject = gameObject
|
||||
this.jiesuoBtn = Util.GetGameObject(this.gameObject, "topBar/jiesuoBtn")
|
||||
this.jiesuoBtnText = Util.GetGameObject(this.jiesuoBtn, "Text"):GetComponent("Text")
|
||||
this.select = Util.GetGameObject(this.gameObject, "topBar/select")
|
||||
this.select = Util.GetGameObject(this.gameObject, "topBar/select")
|
||||
this.weekTrailBtn = Util.GetGameObject(this.gameObject, "topBar/button/weekTrail")
|
||||
this.finalTrailBtn = Util.GetGameObject(this.gameObject, "topBar/button/finalTrail")
|
||||
|
||||
this.weekTrailBtnRed = Util.GetGameObject(this.weekTrailBtn , "redPoint")
|
||||
this.finalTrailBtnRed = Util.GetGameObject(this.finalTrailBtn, "redPoint")
|
||||
this.remainTime = Util.GetGameObject(this.gameObject, "topBar/remainTime/Text"):GetComponent("Text")
|
||||
|
||||
this.treasureList = Util.GetGameObject(this.gameObject, "itemList")
|
||||
|
@ -74,6 +75,7 @@ function this:RemoveListener()
|
|||
Game.GlobalEvent:RemoveEvent(GameEvent.TreasureOfHeaven.RechargeQinglongSerectSuccess, this.refresh,curType)
|
||||
Game.GlobalEvent:RemoveEvent(GameEvent.TreasureOfHeaven.TaskRefresh, this.RefreshTime)
|
||||
Game.GlobalEvent:RemoveEvent(GameEvent.Activity.OnActivityOpenOrClosen,this.CloseFunction)
|
||||
|
||||
Game.GlobalEvent:RemoveEvent(GameEvent.MoneyPay.OnPayResultSuccess, this.refresh,curType)
|
||||
end
|
||||
|
||||
|
@ -160,9 +162,15 @@ function this.refresh(type)
|
|||
this:SetSelect()
|
||||
this:ShowTime(type)
|
||||
this:showTaskList(type)
|
||||
this:SetRedPoint()
|
||||
CheckRedPointStatus(RedPointType.QinglongSerectTreasureTrail)
|
||||
|
||||
end
|
||||
|
||||
function this:SetRedPoint()
|
||||
this.weekTrailBtnRed:SetActive(QinglongSerectTreasureManager.GetSerectTreasureTrailSingleRedPot(1))
|
||||
this.finalTrailBtnRed:SetActive(QinglongSerectTreasureManager.GetSerectTreasureTrailSingleRedPot(2))
|
||||
end
|
||||
|
||||
--任务列表
|
||||
function this:showTaskList(type)
|
||||
|
|
|
@ -232,4 +232,18 @@ function this.GetSerectTreasureTrailRedPot()
|
|||
end
|
||||
return false
|
||||
end
|
||||
|
||||
function this.GetSerectTreasureTrailSingleRedPot(_type)
|
||||
if not ActivityGiftManager.GetActivityOpenStatus(ActivityTypeDef.TreasureOfSomeBody) then
|
||||
return false
|
||||
end
|
||||
local task = this.GetQinglongTaskData(_type)
|
||||
for i, v in pairs(task) do
|
||||
if v.state == 1 then
|
||||
return true
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
||||
return this
|
|
@ -294,7 +294,6 @@ function this.GetMianTaskCurActiveTaskData()
|
|||
return nil
|
||||
end
|
||||
function this.ResetTreasureTaskInfo(taskList)
|
||||
local refreshTypeList = {}
|
||||
--type,tasks
|
||||
for i = 1, #taskList do
|
||||
local taskInfoList = TypeTaskData[TaskTypeDef.TreasureOfSomeBody]
|
||||
|
@ -304,14 +303,9 @@ function this.ResetTreasureTaskInfo(taskList)
|
|||
table.remove(TypeTaskData[TaskTypeDef.TreasureOfSomeBody], k)
|
||||
end
|
||||
end
|
||||
for j = 1, #taskList[i].tasks do
|
||||
table.insert(TypeTaskData[TaskTypeDef.TreasureOfSomeBody], taskList[i].tasks[j])
|
||||
end
|
||||
table.insert(refreshTypeList,taskList[i].type)
|
||||
this.SetSLrefreshTime2(taskList[i].type,taskList[i].refreshTime)
|
||||
table.insert(TypeTaskData[TaskTypeDef.TreasureOfSomeBody], taskList[i].tasks[i])
|
||||
end
|
||||
Game.GlobalEvent:DispatchEvent(GameEvent.MissionDaily.OnMissionListRestChanged,refreshTypeList)
|
||||
CheckRedPointStatus(RedPointType.TreasureOfSl)
|
||||
CheckRedPointStatus(RedPointType.QinglongSerectTreasureTrail)
|
||||
end
|
||||
|
||||
--迷宫寻宝前端刷新任务自行赋值
|
||||
|
|
Loading…
Reference in New Issue