主题活动限时召唤,乾坤宝盒卡死提交

dev_chengFeng
jiaoyangna 2021-07-16 16:23:35 +08:00
parent a70f45e7a5
commit 360a8d3cae
2 changed files with 12 additions and 6 deletions

View File

@ -24,7 +24,7 @@ local isLimitUpHero=false
--初始化组件(用于子类重写)
function QianKunBoxBuyTenPanel:InitComponent()
this.spLoader = SpriteLoader.New()
this.UpView = SubUIManager.Open(SubUIConfig.UpView, self.gameObject.transform, { showType = UpViewOpenType.ShowLeft, panelType = PanelType.ElementDrawCard })
orginLayer = 0
self.bg = Util.GetGameObject(self.gameObject, "effect")
screenAdapte(self.bg)
@ -147,6 +147,9 @@ function QianKunBoxBuyTenPanel:OnOpen(...)
if upConfig then
local wish=ConfigManager.GetConfigData(ConfigName.WishActivitySetting,1)
if wish then
if not this.UpView then
this.UpView = SubUIManager.Open(SubUIConfig.UpView, self.gameObject.transform, { showType = UpViewOpenType.ShowLeft, panelType = PanelType.ElementDrawCard })
end
this.UpView:OnOpen({ showType = UpViewOpenType.ShowLeft, panelType = PanelType.TimelimitCall })
isLimitUpHero=true
this.itemInfo3.text="10次"
@ -155,7 +158,10 @@ function QianKunBoxBuyTenPanel:OnOpen(...)
end
else
d = RecruitManager.GetExpendData(this.recruitType)
SubUIManager.Close(this.UpView)
if this.UpView then
SubUIManager.Close(this.UpView)
this.UpView = nil
end
end
itemId=d[1]
itemNum=d[2]
@ -208,13 +214,13 @@ end
--界面关闭时调用(用于子类重写)
function QianKunBoxBuyTenPanel:OnClose()
end
--界面销毁时调用(用于子类重写)
function QianKunBoxBuyTenPanel:OnDestroy()
this.spLoader:Destroy()
SubUIManager.Close(this.UpView)
this.UpView = nil
this.views = nil
end

View File

@ -292,9 +292,9 @@ function TimeLimitUpHero:Recruit(actId,type,itemId)
--UIManager.OpenPanel(UIName.SingleRecruitPanel, msg.drop.Hero,actId,type,{RecruitType.TimeLimitSingle,RecruitType.TimeLimitTen})
UIManager.OpenPanel(UIName.QianKunBoxBuyTenPanel, msg.drop,actId,{RecruitType.PrayerSingle,RecruitType.PrayerTen},tenFunc)
end
if msg.drop.Hero[1] then
UIManager.OpenPanel(UIName.SingleRecruitPanel, msg.drop.Hero[1],actId,1,{RecruitType.PrayerSingle,RecruitType.PrayerTen},oneFunc2)
end
-- if msg.drop.Hero[1] then
-- UIManager.OpenPanel(UIName.SingleRecruitPanel, msg.drop.Hero[1],actId,1,{RecruitType.PrayerSingle,RecruitType.PrayerTen},oneFunc2)
-- end
CheckRedPointStatus(RedPointType.TimeLimitWish)
end,self.freeTimesId)
end