【(送神祠)选择属性筛选后进行恭送神将、神将归元、法宝归元、宝物分解优化】
parent
c96aedc923
commit
238c0706c0
|
@ -27,6 +27,8 @@ this.MapView = 0
|
|||
this.IsGetFiveStarHero = false
|
||||
|
||||
this.headBookListTag = 1
|
||||
|
||||
this.now_index = 0
|
||||
local update = function()
|
||||
local dt = Time.unscaledDeltaTime
|
||||
this.serverTime = this.serverTime + dt
|
||||
|
|
|
@ -55,7 +55,7 @@ function ResolvePanel:InitComponent()
|
|||
|
||||
|
||||
this.selectHeroBtn = Util.GetGameObject(this.panel, "endTabs/selectBtn")
|
||||
for i = 1, 6 do
|
||||
for i = 1, 5 do
|
||||
heroEndBtns[i]=Util.GetGameObject(this.panel, "endTabs/btnHeroGrid/btnHeroGrid/Btn"..i-1)
|
||||
end
|
||||
for i = 1, #this.contents do
|
||||
|
@ -85,6 +85,7 @@ function ResolvePanel:BindEvent()
|
|||
|
||||
for i = 1, 6 do
|
||||
Util.AddClick( heroEndBtns[i], function()
|
||||
print("来之前"..tabSortType)
|
||||
if tabSortType == i-1 then
|
||||
tabSortType = 0
|
||||
this.contents[curIndex].view.SortTypeClick(0)--全部
|
||||
|
@ -94,7 +95,8 @@ function ResolvePanel:BindEvent()
|
|||
this.contents[curIndex].view.SortTypeClick(i-1)
|
||||
this.EndTabBtnSelect(heroEndBtns[i])
|
||||
end
|
||||
|
||||
PlayerManager.now_index = tabSortType
|
||||
print("来之后"..tabSortType)
|
||||
end)
|
||||
end
|
||||
end
|
||||
|
@ -140,6 +142,9 @@ function ResolvePanel:OnClose()
|
|||
for i = 1, #this.contents do
|
||||
this.contents[i].view:OnClose()
|
||||
end
|
||||
this.RewardGridGoMov(false)
|
||||
PlayerManager.now_index = 0
|
||||
this.EndTabBtnSelect()
|
||||
end
|
||||
|
||||
function ResolvePanel:OnDestroy()
|
||||
|
@ -151,10 +156,16 @@ end
|
|||
|
||||
--切换视图
|
||||
function this.SwitchView(index)
|
||||
this.RewardGridGoMov(false)
|
||||
|
||||
--先执行上一面板关闭逻辑
|
||||
local oldSelect
|
||||
oldSelect, curIndex = curIndex, index
|
||||
if oldSelect ~= curIndex then
|
||||
-- body
|
||||
this.RewardGridGoMov(false)
|
||||
PlayerManager.now_index = 0
|
||||
end
|
||||
|
||||
for i = 1, #this.contents do
|
||||
if oldSelect~=0 then this.contents[oldSelect].view:OnClose() break end
|
||||
end
|
||||
|
@ -189,10 +200,11 @@ function this.SwitchView(index)
|
|||
this.title:SetNativeSize()
|
||||
|
||||
--执行子模块初始化
|
||||
|
||||
this.contents[index].view:OnShow(this.sortingOrder,this.itemListRoot)
|
||||
--刷新选择按钮
|
||||
tabSortType = 0
|
||||
this.EndTabBtnSelect()
|
||||
this.EndTabBtnSelect(heroEndBtns[PlayerManager.now_index + 1])
|
||||
end
|
||||
|
||||
-- tab节点显示自定义
|
||||
|
|
|
@ -36,6 +36,7 @@ function this:BindEvent()
|
|||
if tonumber(LengthOfTable(selectHeroData))==0 then
|
||||
PopupTipPanel.ShowTip(Language[11787])
|
||||
else
|
||||
|
||||
UIManager.OpenPanel(UIName.GeneralPopup,GENERAL_POPUP_TYPE.ResolveDismantle,
|
||||
HeroManager.GetHeroReturnItems(selectHeroData,GENERAL_POPUP_TYPE.ResolveDismantle),selectHeroData)
|
||||
end
|
||||
|
@ -67,8 +68,9 @@ function this:RemoveListener()
|
|||
end
|
||||
|
||||
function this:OnShow(...)
|
||||
sortingOrder =0
|
||||
sortingOrder = PlayerManager.now_index or 0
|
||||
this.SortTypeClick(sortingOrder)
|
||||
|
||||
end
|
||||
|
||||
--展示数据
|
||||
|
|
|
@ -63,6 +63,9 @@ end
|
|||
|
||||
function this:OnShow(...)
|
||||
sortingOrder =0
|
||||
sortingOrder = PlayerManager.now_index or 0
|
||||
|
||||
LogGreen(PlayerManager.now_index)
|
||||
this.SortTypeClick(sortingOrder)
|
||||
end
|
||||
|
||||
|
|
|
@ -55,9 +55,9 @@ end
|
|||
function this:OnShow(...)
|
||||
local args={...}
|
||||
sortingOrder =args[1]
|
||||
sortType =0
|
||||
|
||||
sortType = PlayerManager.now_index or 0
|
||||
|
||||
LogGreen(PlayerManager.now_index)
|
||||
this.SortTypeClick(sortType)
|
||||
end
|
||||
|
||||
|
|
|
@ -52,8 +52,10 @@ end
|
|||
function this:OnShow(...)
|
||||
local args={...}
|
||||
sortingOrder =args[1]
|
||||
sortType =0
|
||||
|
||||
sortType = PlayerManager.now_index or 0
|
||||
|
||||
LogGreen(PlayerManager.now_index)
|
||||
|
||||
this.SortTypeClick(sortType)
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue