PGRData/Script/matrix/xredpoint/xredpointconditions/XRedPointConditionMoeWarTask.lua

22 lines
No EOL
562 B
Lua

local XRedPointConditionMoeWarTask = {}
local Events = nil
function XRedPointConditionMoeWarTask.GetSubEvents()
Events = Events or
{
XRedPointEventElement.New(XEventId.EVENT_TASK_SYNC),
XRedPointEventElement.New(XEventId.EVENT_FINISH_TASK),
}
return Events
end
function XRedPointConditionMoeWarTask.Check()
local taskCount = XMoeWarConfig.GetTaskGroupCount()
for i = 1,taskCount do
if XDataCenter.MoeWarManager.CheckTaskRedPoint(i,XMoeWarConfig.GetTaskGroupId(i)) then
return true
end
end
return false
end
return XRedPointConditionMoeWarTask