public override void OnExit() { if (GameFlowHotfixController.PreviousActiveStateName != null) { PartitionObject.FlushAllAndUnload(); } base.OnExit(); CombatLogic.Instance.ExitCombat(); if (GameFlowHotfixController.PreviousActiveStateName != null) { if (PSPoolManager.Instance != null) { PSPoolManager.Instance.CompressPool(); PSPoolManager.Instance.UnloadStandardCombatFX(); } EB.Assets.UnloadBundle("SpiritAnimaFx"); } //暴力释放掉战斗场景资源 if (m_ThemeLoadManager != null) { F_Clear(m_ThemeLoadManager.GetSceneRoot().m_LevelAssets); } EventManager.instance.Raise(eSimpleEventID.Combat_Exit); }
public override void OnEnter() { LoadingLogic.AddCustomProgress(10); hudLoaded = false; sceneLoaded = false; PartitionObject.FlushAllAndUnload(); base.OnEnter(); FusionAudio.PostGlobalMusicEvent("MUS_CampaignView_Demo", true); Hotfix_LT.Messenger.AddListener <EnemyController, eBattleType>("AttackEnemyImediatly", AttackEnemyImediatly); Hotfix_LT.Messenger.Raise("LTSpeedSnatchEvent.IdleFollow"); MainlandViewAction(); LTWelfareModel.Instance.SetMaxCampaignLevel();//更新通关的最大章节 }