新英雄上阵修改提交
parent
2f17b7af58
commit
5999c18900
|
@ -125,6 +125,7 @@ function this:InitComponent()
|
|||
--筛选按钮
|
||||
for i = 0, 5 do
|
||||
tabs[i] = Util.GetGameObject(this.gameObject, "Tabs/Grid/Btn" .. i)
|
||||
tabs[i]:SetActive(true)
|
||||
if tabsImg[i + 1] then
|
||||
Util.GetGameObject(tabs[i], "Image"):GetComponent("Image").sprite = this.spLoader:LoadSprite(tabsImg[i + 1])
|
||||
end
|
||||
|
@ -853,13 +854,13 @@ function this.SingleHeroDataShow(_go, _heroData)
|
|||
else
|
||||
redPot.gameObject:SetActive(false)
|
||||
end
|
||||
if _heroData.property then
|
||||
changeProBtn:SetActive(_heroData.property>=5)
|
||||
pro.sprite= this.spLoader:LoadSprite(GetProStrImageByProNum(heroData.property))
|
||||
else
|
||||
-- if _heroData.property then
|
||||
-- changeProBtn:SetActive(_heroData.property>=5)
|
||||
-- pro.sprite= this.spLoader:LoadSprite(GetProStrImageByProNum(heroData.property))
|
||||
-- else
|
||||
changeProBtn:SetActive(false)
|
||||
pro.sprite= this.spLoader:LoadSprite(GetProStrImageByProNum(heroData.heroConfig.PropertyName))
|
||||
end
|
||||
--end
|
||||
icon.sprite=this.spLoader:LoadSprite(heroData.icon)
|
||||
local level=heroData.lv
|
||||
pos.sprite = this.spLoader:LoadSprite(heroData.professionIcon)
|
||||
|
@ -1001,13 +1002,13 @@ function this.SingleHeroDataShow(_go, _heroData)
|
|||
end
|
||||
-- 点击事件
|
||||
Util.AddOnceClick(go, function()
|
||||
if heroData.property and heroData.property>=5 then
|
||||
UIManager.OpenPanel(UIName.GeneralPopup,GENERAL_POPUP_TYPE.ChangeHeroPro,heroData,function()
|
||||
LogError("刷新界面数据")
|
||||
this.RefreshShow(false,false)
|
||||
end)
|
||||
return
|
||||
end
|
||||
-- if heroData.property and heroData.property>=5 then
|
||||
-- UIManager.OpenPanel(UIName.GeneralPopup,GENERAL_POPUP_TYPE.ChangeHeroPro,heroData,function()
|
||||
-- LogError("刷新界面数据")
|
||||
-- this.RefreshShow(false,false)
|
||||
-- end)
|
||||
-- return
|
||||
-- end
|
||||
-- 判断是上阵还是下阵
|
||||
local formationAction = FORMATION_ACTION.UP
|
||||
for k, v in ipairs(this.choosedList) do
|
||||
|
|
|
@ -32,7 +32,7 @@ function this:InitComponent(gameObject)
|
|||
this.selectBtn=Util.GetGameObject(gameObject, "Tabs/selectBtn")
|
||||
this.hintTxt=Util.GetGameObject(gameObject, "tipTxt")
|
||||
this.btns={}
|
||||
for i = 1, 4 do
|
||||
for i = 1, 5 do
|
||||
this.btns[i]=Util.GetGameObject(gameObject, "Tabs/grid/Btn"..i)
|
||||
end
|
||||
|
||||
|
@ -48,7 +48,7 @@ function this:BindEvent()
|
|||
Util.AddClick(this.cancelBtn,function()
|
||||
parent:ClosePanel()
|
||||
end)
|
||||
for i = 1, 4 do
|
||||
for i = 1, 5 do
|
||||
Util.AddClick(this.btns[i], function()
|
||||
if i == curProId then
|
||||
return
|
||||
|
|
Loading…
Reference in New Issue