编队修改
parent
3deb27c862
commit
384b3b35c3
|
@ -421,11 +421,15 @@ end
|
||||||
-- 获取所有正在编队的英雄id
|
-- 获取所有正在编队的英雄id
|
||||||
function this.AllFormationDeleCurHeroId(heroDid)
|
function this.AllFormationDeleCurHeroId(heroDid)
|
||||||
for i, team in pairs(this.formationList) do
|
for i, team in pairs(this.formationList) do
|
||||||
|
local removeIndex
|
||||||
for j = 1, #team.teamHeroInfos do
|
for j = 1, #team.teamHeroInfos do
|
||||||
if team.teamHeroInfos[j] and team.teamHeroInfos[j].heroId == heroDid then
|
if team.teamHeroInfos[j] and team.teamHeroInfos[j].heroId == heroDid then
|
||||||
team.teamHeroInfos[j] = nil
|
removeIndex = j
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
if removeIndex then
|
||||||
|
table.remove( team.teamHeroInfos, removeIndex)
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -650,7 +650,7 @@ function this.GetUpStarHeroListData(heroRankUpGroupId, heroData)
|
||||||
for n, w in pairs(FormationManager.formationList) do
|
for n, w in pairs(FormationManager.formationList) do
|
||||||
if this.heroResolveLicence[n] then
|
if this.heroResolveLicence[n] then
|
||||||
for m = 1, #w.teamHeroInfos do
|
for m = 1, #w.teamHeroInfos do
|
||||||
if v.dynamicId == w.teamHeroInfos[m].heroId then
|
if w.teamHeroInfos[m] and v.dynamicId == w.teamHeroInfos[m].heroId then
|
||||||
local isFormationStr = this.GetHeroFormationStr(n)
|
local isFormationStr = this.GetHeroFormationStr(n)
|
||||||
v.isFormation = isFormationStr
|
v.isFormation = isFormationStr
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue