From a3a5d77932c1d6ad58d01d144183c45735ca77c0 Mon Sep 17 00:00:00 2001
From: hch <305670599@qq.com>
Date: 星期三, 24 十二月 2025 22:36:54 +0800
Subject: [PATCH] 0312 优化引导非强制引导的衔接
---
Main/System/NewBieGuidance/NewBieGuideScriptableObject.cs | 1 +
Main/System/HeroUI/HeroBaseWin.cs | 15 +++++++++++----
Main/System/Main/MainWin.cs | 2 +-
Main/System/HappyXB/HappyXBModel.cs | 1 +
Main/System/NewBieGuidance/NewBieWin.cs | 8 +++++++-
5 files changed, 21 insertions(+), 6 deletions(-)
diff --git a/Main/System/HappyXB/HappyXBModel.cs b/Main/System/HappyXB/HappyXBModel.cs
index 28dd01d..faf75db 100644
--- a/Main/System/HappyXB/HappyXBModel.cs
+++ b/Main/System/HappyXB/HappyXBModel.cs
@@ -41,6 +41,7 @@
public int lhQuality;
public int tenCallGuideID = 0;
+ public bool startTenCallGuide = false;
public override void Init()
{
diff --git a/Main/System/HeroUI/HeroBaseWin.cs b/Main/System/HeroUI/HeroBaseWin.cs
index 5342bd9..422fab3 100644
--- a/Main/System/HeroUI/HeroBaseWin.cs
+++ b/Main/System/HeroUI/HeroBaseWin.cs
@@ -24,16 +24,23 @@
}
+ protected override void OnOpen()
+ {
+ if (HappyXBModel.Instance.startTenCallGuide)
+ {
+ NewBieCenter.Instance.StartNewBieGuide(HappyXBModel.Instance.tenCallGuideID);
+ HappyXBModel.Instance.startTenCallGuide = false;
+
+ }
+ }
+
protected override void OnPreClose()
{
base.OnPreClose();
+
}
- public override void Refresh()
- {
-
- }
diff --git a/Main/System/Main/MainWin.cs b/Main/System/Main/MainWin.cs
index a19babd..5eb3a31 100644
--- a/Main/System/Main/MainWin.cs
+++ b/Main/System/Main/MainWin.cs
@@ -303,7 +303,7 @@
{
if (!NewBieCenter.Instance.inGuiding)
{
- NewBieCenter.Instance.StartNewBieGuide(HappyXBModel.Instance.tenCallGuideID);
+ HappyXBModel.Instance.startTenCallGuide = true;
}
}
currentSubUI = UIManager.Instance.OpenWindow<HeroBaseWin>(0);
diff --git a/Main/System/NewBieGuidance/NewBieGuideScriptableObject.cs b/Main/System/NewBieGuidance/NewBieGuideScriptableObject.cs
index 155e93f..c97395d 100644
--- a/Main/System/NewBieGuidance/NewBieGuideScriptableObject.cs
+++ b/Main/System/NewBieGuidance/NewBieGuideScriptableObject.cs
@@ -23,6 +23,7 @@
public bool clickAnyWhereComplete = false;
public bool clickCompleteNoMask = false; //闈炲己鍒跺紩瀵硷紝浠绘剰鐐瑰嚮鍏抽棴锛屽嬀閫夋椤逛細闅愯棌钂欑増锛屼笖鐐瑰嚮鍏朵粬鍖哄煙涓嶄細鍝嶅簲鎸夐挳浜嬩欢
public int delayTime = 0; //灞曠ず鏃堕棿锛堟绉掞級锛屾湡闂翠笉鍙偣鍑�
+ public string needWinName;
// 寮曞鐨勬枃鏈殑绠ご浣嶇疆
public enum ArrowPosition
diff --git a/Main/System/NewBieGuidance/NewBieWin.cs b/Main/System/NewBieGuidance/NewBieWin.cs
index a630c6e..4b601cc 100644
--- a/Main/System/NewBieGuidance/NewBieWin.cs
+++ b/Main/System/NewBieGuidance/NewBieWin.cs
@@ -140,6 +140,12 @@
{
m_lastTargetPosition = m_ClickTarget.position;
tryGuideCount = 0;
+ if (!string.IsNullOrEmpty(stepConfig.needWinName) && !UIManager.Instance.IsOpened(stepConfig.needWinName))
+ {
+ Debug.Log($"寮曞姝ラ{step}闇�瑕佹墦寮�绐楀彛{stepConfig.needWinName}");
+ ReportStepOver();
+ return;
+ }
}
else
{
@@ -147,7 +153,7 @@
{
#if UNITY_EDITOR
- if (!string.IsNullOrEmpty(stepConfig.UIElementPath))
+ if (!string.IsNullOrEmpty(stepConfig.UIElementPath) && string.IsNullOrEmpty(stepConfig.needWinName))
Debug.LogError($"寮曞姝ラ{step}鎵句笉鍒扮洰鏍噞stepConfig.UIElementPath}, 鑻ヤ笉闇�瑕佽鍒犻櫎璺緞");
#endif
ReportStepOver();
--
Gitblit v1.8.0