【魂印 神印】==========================穿戴修改

TCX_dev_realOne_master
wangzhenxing 2023-12-26 17:49:15 +08:00
parent e7e8bb0990
commit f961a7b87e
2 changed files with 43 additions and 16 deletions

View File

@ -4183,9 +4183,9 @@ function this.CheckHeroIsCanAddGodPrint(index,herodata)
elseif index==2 then
isCan=herodata.heroConfig.Profession==2
elseif index==3 then
isCan=herodata.heroConfig.Profession==4
elseif index==4 then
isCan=herodata.heroConfig.Profession==3
elseif index==4 then
isCan=herodata.heroConfig.Profession==4
elseif index==5 then
isCan=herodata.heroConfig.Job==1
elseif index==6 then

View File

@ -269,14 +269,14 @@ function this.SetLoopUI()
local rules=v.OpenRules
if rules[1]==1 then
if PlayerManager.level<rules[2] then
this.SetLoopPre(loopList[loopCount],2,nil,didLv)
this.SetLoopPre(loopList[loopCount],2,v.SlotPosition,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)
this.SetLoopPre(loopList[loopCount],2,v.SlotPosition,didLv)
break
else
this.SetLoopPre(loopList[loopCount],1)
@ -286,8 +286,8 @@ function this.SetLoopUI()
--数据赋值
for k=1,#curHeroData.soulPrintList do
local index=curHeroData.soulPrintList[k].position
this.SetLoopPre(loopList[index],3,index,curHeroData.soulPrintList[k])
local index=k --curHeroData.soulPrintList[k].position
this.SetLoopPre(loopList[index],3,k,curHeroData.soulPrintList[k])
end
end
function this.GetSoulLockTip()
@ -345,7 +345,7 @@ function this.SetLoopPre(root,type,index,data,curIndex)
Util.GetGameObject(unlock,"circle"):GetComponent("Image").sprite=this.spLoader:LoadSprite(SoulPrintSpriteByQuantity[equipConfig[data.equipId].Quality].circle)
Util.GetGameObject(unlock,"Name"):GetComponent("Text").text=GetLanguageStrById(itemConfig[data.equipId].Name)
Util.AddOnceClick(root,function()
local pos=index
local pos=data.position
LogBlue("卸下时 "..data.equipId)
UIManager.OpenPanel(UIName.SoulPrintPopUp,2,curHeroData.dynamicId,data.equipId,pos,function()
PopupTipPanel.ShowTip(Language[11904])
@ -464,19 +464,46 @@ end
--自动获取魂印的位置 如果有位置返回位置 如果没位置返回0
function this.GetPos()
local _data={}
for k=1,loopCount do
if Util.GetGameObject(loopList[k].gameObject,"UnLock").activeSelf then
table.insert(_data,k,k)
-- for k=1,loopCount do
-- if Util.GetGameObject(loopList[k].gameObject,"UnLock").activeSelf then
-- table.insert(_data,k,k)
-- end
-- end
-- for i = 1, loopCount do
-- if _data[i]==nil then
-- return i
-- end
-- if didLen == LengthOfTable(_data) then
-- return 0
-- end
-- end
local _d = {}
for k, v in ConfigPairs(equipSignSetting) do
if v.OpenRules then
if v.OpenRules[1]==1 then
if PlayerManager.level >= v.OpenRules[2] then
table.insert(_d, v.SlotPosition)
end
elseif v.OpenRules[1]==2 then
if curHeroData.star>=v.OpenRules[2] then
table.insert(_d, v.SlotPosition)
end
end
end
end
for i = 1, loopCount do
if _data[i]==nil then
return i
end
if didLen == LengthOfTable(_data) then
return 0
local wearList={}
if curHeroData.soulPrintList and #curHeroData.soulPrintList>0 then
for k, v in pairs(curHeroData.soulPrintList) do
table.insert(wearList,v.position)
end
end
for i=1,#_d do
if CheckListIsContainValue1(wearList,_d[i])==false then
return _d[i]
end
end
return 0
end
function this.ShowRedPotDataAndSort(allData)
local didMaxLen,didLen,didLv,maxLv = HeroManager.GetSoulPrintLoopUIMaxData(curHeroData)