魂印开启显示修改提交

onepiece_demo_arena
wangzhenxing 2023-12-05 14:32:44 +08:00
parent e7ef5dde40
commit 2f351a2052
1 changed files with 23 additions and 15 deletions

View File

@ -243,11 +243,15 @@ function this.SetLoopUI()
LogError("最大槽位数量"..loopCount.." 可装备槽位数量"..didLen.." 最大动态等级"..didLv.." 配置最大等级"..maxLv)
--初始化
for i=1, #loopList do
loopList[i]:SetActive(false)
end
for i=1,loopCount do
if not loopList[i] then
loopList[i]=newObjToParent(this.loopPre,this.loopRoot)
end
loopList[i].name="Pre"..i
loopList[i]:SetActive(true)
end
--设置不包含最后一位 为默认
for j=1,loopCount do
@ -260,22 +264,26 @@ function this.SetLoopUI()
this.SetLoopPre(loopList[j],1,nil,nil,j)
end
end
--最后一位锁定
local rules=equipSignSetting[maxLv].OpenRules
if rules[1]==1 then
if PlayerManager.level<rules[2] then
this.SetLoopPre(loopList[loopCount],2,nil,didLv)
else
this.SetLoopPre(loopList[loopCount],1)
end
elseif rules[1]==2 then
if curHeroData.star<rules[2] then
this.SetLoopPre(loopList[loopCount],2,nil,didLv)
else
this.SetLoopPre(loopList[loopCount],1)
end
end
--最后一位锁定
for k, v in ConfigPairs(equipSignSetting) do
local rules=v.OpenRules
if rules[1]==1 then
if PlayerManager.level<rules[2] then
this.SetLoopPre(loopList[loopCount],2,nil,didLv)
break
else
this.SetLoopPre(loopList[loopCount],1)
end
elseif rules[1]==2 then
if curHeroData.star<rules[2] then
this.SetLoopPre(loopList[loopCount],2,nil,didLv)
break
else
this.SetLoopPre(loopList[loopCount],1)
end
end
end
--数据赋值
for k=1,#curHeroData.soulPrintList do
local index=curHeroData.soulPrintList[k].position