碎片tips显示错误
This commit is contained in:
parent
fe8d9aede1
commit
88aa6a6cf3
@ -23,7 +23,7 @@ function HeroFragmentTips:onLoadRootComplete()
|
||||
end
|
||||
self.heroList = {}
|
||||
for _, v in ipairs(drop) do
|
||||
if DataManager.HeroData:getHeroIsActive(v.id) then
|
||||
if DataManager.HeroData:getHeroIsUnlock(v.id) then
|
||||
table.insert(self.heroList, v.id)
|
||||
end
|
||||
end
|
||||
|
||||
@ -84,6 +84,15 @@ function HeroData:getHeroIsActive(id)
|
||||
return entity:isActived()
|
||||
end
|
||||
|
||||
|
||||
function HeroData:getHeroIsUnlock(id)
|
||||
local entity = self.heroes[id]
|
||||
if entity == nil then
|
||||
return false
|
||||
end
|
||||
return entity:isUnlock()
|
||||
end
|
||||
|
||||
function HeroData:getUnlockHeroCount()
|
||||
local count = 0
|
||||
for id, entity in pairs(self.heroes) do
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user