parent
9dd81f082d
commit
645fa025a8
|
@ -547,7 +547,16 @@ function FightPointPassMainPanel:OnShow()
|
|||
-- 刷新关卡按钮状态
|
||||
this.SetFightBtnText()
|
||||
|
||||
|
||||
local loadMapName = fightLevelConfig[FightPointPassManager.curOpenFight].BG
|
||||
LogError("@@@@@@"..loadMapName)
|
||||
if this.mapName ~= loadMapName then
|
||||
this.mapName = loadMapName
|
||||
if this.mapGameObject ~= nil then
|
||||
GameObject.Destroy(this.mapGameObject)
|
||||
end
|
||||
this.mapGameObject = BattleManager.CreateMap(this.battleSceneGameObject, loadMapName)
|
||||
fightOnHook:UpdateMap(this.mapGameObject)
|
||||
end
|
||||
if not hasLoad then
|
||||
timePressStarted = Time.realtimeSinceStartup
|
||||
isAnimActive = false
|
||||
|
@ -572,15 +581,7 @@ function FightPointPassMainPanel:OnShow()
|
|||
callBack = nil
|
||||
end
|
||||
end
|
||||
local loadMapName = fightLevelConfig[FightPointPassManager.curOpenFight].BG
|
||||
if this.mapName ~= loadMapName then
|
||||
this.mapName = loadMapName
|
||||
if this.mapGameObject ~= nil then
|
||||
GameObject.Destroy(this.mapGameObject)
|
||||
end
|
||||
this.mapGameObject = BattleManager.CreateMap(this.battleSceneGameObject, loadMapName)
|
||||
fightOnHook:UpdateMap(this.mapGameObject)
|
||||
end
|
||||
|
||||
this.BtnsIsOpen()
|
||||
--寻宝显示
|
||||
this.UpdateFindTreasureMaterialNum()
|
||||
|
@ -1022,7 +1023,7 @@ function FightPointPassMainPanel:OnDestroy()
|
|||
end
|
||||
|
||||
this.mapGameObject = nil
|
||||
|
||||
this.mapName = nil
|
||||
if this.battleSceneGameObject ~= nil then
|
||||
GameObject.Destroy(this.battleSceneGameObject)
|
||||
this.battleSceneGameObject = nil
|
||||
|
|
Loading…
Reference in New Issue