PGRData/Resources/Scripts/XRedPoint/XRedPointConditions/XRedPointConditionMoeWarDrawRed.lua
2022-12-26 14:06:01 +05:30

18 lines
No EOL
605 B
Lua

local XRedPointConditionMoeWarDrawRed = {}
local Events = nil
local itemId = CS.XGame.ClientConfig:GetInt("MoeWarGachaItem")
local showCount = CS.XGame.ClientConfig:GetInt("MoeWarGachaItemNum")
function XRedPointConditionMoeWarDrawRed.GetSubEvents()
Events = Events or
{
XRedPointEventElement.New(XEventId.EVENT_ITEM_COUNT_UPDATE_PREFIX..itemId),
}
return Events
end
function XRedPointConditionMoeWarDrawRed.Check()
local itemCount = XDataCenter.ItemManager.GetCount(itemId)
return itemCount >= showCount
end
return XRedPointConditionMoeWarDrawRed