From 265131d083cdc0d89ccaeb3690e0aaf7b7dc2299 Mon Sep 17 00:00:00 2001 From: zhangaotian <8474238@qq.com> Date: Thu, 22 Aug 2024 17:29:54 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90Bug=E3=80=91=E6=88=98=E6=96=97?= =?UTF-8?q?=E4=B8=AD=E8=BF=94=E5=9B=9E=E5=BB=BA=E9=80=A0=E5=9C=BA=E6=99=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Scripts/Gameplay/UI/EndPanel/UILosePanelController.cs | 3 ++- .../Scripts/Gameplay/UI/EndPanel/UIWinPanelController.cs | 3 ++- .../Scripts/Gameplay/UI/Level/UIPausePanelController.cs | 7 ++++--- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/Forest/Assets/Scripts/Gameplay/UI/EndPanel/UILosePanelController.cs b/Forest/Assets/Scripts/Gameplay/UI/EndPanel/UILosePanelController.cs index c06f6bb..415f6a8 100644 --- a/Forest/Assets/Scripts/Gameplay/UI/EndPanel/UILosePanelController.cs +++ b/Forest/Assets/Scripts/Gameplay/UI/EndPanel/UILosePanelController.cs @@ -1,5 +1,6 @@ using Event = cfg.BI.Event; using Framework.Constants; +using Framework.Manager; using Gameplay.Manager; using Framework.Event; using Gameplay.Level; @@ -37,7 +38,7 @@ public class UILosePanelController : UIWindow { CloseWindow(true); UIManager.Instance.CloseWindow(UIConstants.UILevelPanel, true); - GameStateManager.Instance.ChangeState(new GameStateStart()); + GameStateManager.Instance.ChangeState(new GameStateStart(BuildManager.Instance.CurBuildInfo.BuildSceneID)); BIManager.Instance.TrackEventLevel(cfg.BI.Event.level_back_home, BIManager.Reason.ClickOnLosePanel.ToString()); } diff --git a/Forest/Assets/Scripts/Gameplay/UI/EndPanel/UIWinPanelController.cs b/Forest/Assets/Scripts/Gameplay/UI/EndPanel/UIWinPanelController.cs index e9c4316..6e2ca94 100644 --- a/Forest/Assets/Scripts/Gameplay/UI/EndPanel/UIWinPanelController.cs +++ b/Forest/Assets/Scripts/Gameplay/UI/EndPanel/UIWinPanelController.cs @@ -7,6 +7,7 @@ using Gameplay.Level; using UnityEngine.UI; using Framework.Event; using Gameplay.Manager; +using Framework.Manager; using System.Collections; using Framework.Constants; @@ -75,7 +76,7 @@ public class UIWinPanelController : UIWindow BIManager.Reason.ClickOnWinPanel.ToString()); CloseWindow(true); UIManager.Instance.CloseWindow(UIConstants.UILevelPanel, true); - GameStateManager.Instance.ChangeState(new GameStateStart()); + GameStateManager.Instance.ChangeState(new GameStateStart(BuildManager.Instance.CurBuildInfo.BuildSceneID)); EventManager.Instance.Send(EventManager.EventName.StartBackToMain); } diff --git a/Forest/Assets/Scripts/Gameplay/UI/Level/UIPausePanelController.cs b/Forest/Assets/Scripts/Gameplay/UI/Level/UIPausePanelController.cs index c0054f6..880087f 100644 --- a/Forest/Assets/Scripts/Gameplay/UI/Level/UIPausePanelController.cs +++ b/Forest/Assets/Scripts/Gameplay/UI/Level/UIPausePanelController.cs @@ -2,9 +2,10 @@ using Framework.BI; using Framework.UI; using Gameplay.Game; using UnityEngine.UI; -using Gameplay.Manager; -using Framework.Constants; using Framework.Event; +using Gameplay.Manager; +using Framework.Manager; +using Framework.Constants; using Event = cfg.BI.Event; public class UIPausePanelController : UIWindow @@ -30,7 +31,7 @@ public class UIPausePanelController : UIWindow BIManager.Instance.TrackEventLevel(Event.level_back_home, BIManager.Reason.ClickOnPausePanel.ToString()); UIManager.Instance.CloseWindow(UIConstants.UIPausePanel, true); UIManager.Instance.CloseWindow(UIConstants.UILevelPanel, true); - GameStateManager.Instance.ChangeState(new GameStateStart()); + GameStateManager.Instance.ChangeState(new GameStateStart(BuildManager.Instance.CurBuildInfo.BuildSceneID)); } private void ContinueLevel()