抽卡立绘显示修改
parent
4ab9d1b98e
commit
a6d0814a13
|
@ -369,7 +369,7 @@ function SingleRecruitPanel:UpdataPanelData(_heroData)
|
||||||
Sound_Recruit3 = SoundManager.PlaySound(SoundConfig.Sound_Recruit3)
|
Sound_Recruit3 = SoundManager.PlaySound(SoundConfig.Sound_Recruit3)
|
||||||
|
|
||||||
if heroStaticData and not IsNull(testLiveGO) then
|
if heroStaticData and not IsNull(testLiveGO) then
|
||||||
poolManager:UnLoadLive(GetResourcePath(heroStaticData.Live), testLiveGO)
|
poolManager:UnLoadLive(GetResourcePath(heroStaticData.Painting), testLiveGO)
|
||||||
heroStaticData, testLiveGO = nil, nil
|
heroStaticData, testLiveGO = nil, nil
|
||||||
end
|
end
|
||||||
heroStaticData = heroConfigData[_heroData.heroId]
|
heroStaticData = heroConfigData[_heroData.heroId]
|
||||||
|
@ -428,13 +428,13 @@ function SingleRecruitPanel:UpdataPanelData(_heroData)
|
||||||
end
|
end
|
||||||
|
|
||||||
--TODO:动态加载立绘
|
--TODO:动态加载立绘
|
||||||
testLiveGO = poolManager:LoadLive(GetResourcePath(heroStaticData.Live), self.live2dRoot.transform,
|
testLiveGO = poolManager:LoadLive(GetResourcePath(heroStaticData.Painting), self.live2dRoot.transform,
|
||||||
Vector3.one * heroStaticData.Scale, Vector3.New(heroStaticData.Position[1],heroStaticData.Position[2],0))
|
Vector3.one * heroStaticData.Scale, Vector3.New(heroStaticData.Position[1],heroStaticData.Position[2],0))
|
||||||
SetHEeroLiveToward(testLiveGO,heroStaticData.Toward,heroStaticData.Position)
|
SetHEeroLiveToward(testLiveGO,heroStaticData.Toward,heroStaticData.Position)
|
||||||
local SkeletonGraphic = testLiveGO:GetComponent("SkeletonGraphic")
|
local SkeletonGraphic = testLiveGO:GetComponent("SkeletonGraphic")
|
||||||
local idle = function() SkeletonGraphic.AnimationState:SetAnimation(0, "idle", true) end
|
local idle = function() SkeletonGraphic.AnimationState:SetAnimation(0, "idle", true) end
|
||||||
SkeletonGraphic.AnimationState.Complete = SkeletonGraphic.AnimationState.Complete + idle
|
SkeletonGraphic.AnimationState.Complete = SkeletonGraphic.AnimationState.Complete + idle
|
||||||
poolManager:SetLiveClearCall(GetResourcePath(heroStaticData.Live), testLiveGO, function ()
|
poolManager:SetLiveClearCall(GetResourcePath(heroStaticData.Painting), testLiveGO, function ()
|
||||||
if SkeletonGraphic and not IsNull(SkeletonGraphic) then
|
if SkeletonGraphic and not IsNull(SkeletonGraphic) then
|
||||||
SkeletonGraphic.AnimationState.Complete = SkeletonGraphic.AnimationState.Complete - idle
|
SkeletonGraphic.AnimationState.Complete = SkeletonGraphic.AnimationState.Complete - idle
|
||||||
end
|
end
|
||||||
|
@ -500,7 +500,7 @@ function SingleRecruitPanel:OnClose()
|
||||||
index=0
|
index=0
|
||||||
this.CloseAllTimer()
|
this.CloseAllTimer()
|
||||||
if heroStaticData then
|
if heroStaticData then
|
||||||
poolManager:UnLoadLive(GetResourcePath(heroStaticData.Live), testLiveGO)
|
poolManager:UnLoadLive(GetResourcePath(heroStaticData.Painting), testLiveGO)
|
||||||
end
|
end
|
||||||
heroStaticData, testLiveGO = nil, nil
|
heroStaticData, testLiveGO = nil, nil
|
||||||
this.StopPanelSound()
|
this.StopPanelSound()
|
||||||
|
|
Loading…
Reference in New Issue