Merge branch 'master_develop' of http://60.1.1.230/gaoxin/JL_Client into master_develop

dev_chengFeng
altair 2020-07-22 14:53:14 +08:00
commit 508b6c284f
2 changed files with 6 additions and 6 deletions

View File

@ -60,6 +60,7 @@ function QianKunBox:InitComponent(gameObject)
self.shop = Util.GetGameObject(gameObject,"shop")
self.shopBack = Util.GetGameObject(self.shop,"shopBack/btnBack")
self.content = Util.GetGameObject(self.shop,"content")
self.livename=nil
self.live = Util.GetGameObject(self.shop,"live")
end
@ -71,17 +72,20 @@ function QianKunBox:BindEvent()
ActivityDetail.new(self.detail,2)
end)
Util.AddClick(self.btnStore,function()
-- Game.GlobalEvent:DispatchEvent(GameEvent.Player.OnCurrencyChange,PanelType.QianKunStore)
self.shop:SetActive(true)
self.btnBack:SetActive(false)
self.tabList:SetActive(false)
self.bottomBar:SetActive(false)
self.livename = "live2d_ui_h_52_xx_pf1"
self.liveNode = poolManager:LoadLive(self.livename, self.live.transform, Vector3.New(0.25,0.25,0.25), Vector3.New(123,214,0))
end)
Util.AddClick(self.shopBack,function()
self.shop:SetActive(false)
self.btnBack:SetActive(true)
self.tabList:SetActive(true)
self.bottomBar:SetActive(true)
poolManager:UnLoadLive(self.livename, self.liveNode)
self.livename = nil
end)
end
@ -199,7 +203,7 @@ function QianKunBox:storeShow()
self.shopView = SubUIManager.Open(SubUIConfig.ShopView, self.content.transform)
end
self.shopView:ShowShop(SHOP_TYPE.QIANKUNBOX_SHOP,orginLayer)
self.live = poolManager:LoadLive("live2d_ui_h_52_xx_pf1", self.live.transform, Vector3.New(0.25,0.25,0.25), Vector3.New(123,214,0))
end
--时间
@ -235,14 +239,10 @@ function QianKunBox:OnHide()
self.timer:Stop()
self.timer = nil
end
end
function QianKunBox:OnDestroy()
if self.shopView then
self.shopView = SubUIManager.Close(self.shopView)
self.shopView = nil
end
poolManager:UnLoadLive("live2d_ui_h_52_xx_pf1", self.live)
end
return QianKunBox