From 3e2a34a04bc4a8a2827ca0407a0f7635bce56722 Mon Sep 17 00:00:00 2001
From: lcy <1459594991@qq.com>
Date: 星期四, 27 十一月 2025 11:45:36 +0800
Subject: [PATCH] 362 【付费内容】特权卡-补充 支持配表设置跳过战斗

---
 Main/System/Battle/BaseBattleWin.cs |   47 +++++++++++++++++++++++++++++++++++++++++------
 1 files changed, 41 insertions(+), 6 deletions(-)

diff --git a/Main/System/Battle/BaseBattleWin.cs b/Main/System/Battle/BaseBattleWin.cs
index 1880e9e..604ec76 100644
--- a/Main/System/Battle/BaseBattleWin.cs
+++ b/Main/System/Battle/BaseBattleWin.cs
@@ -194,17 +194,49 @@
         if (!FuncOpen.Instance.IsFuncOpen(BattleManager.Instance.passFuncId, true))
             return;
 
-        //涓荤嚎Boss涔嬪鐨勬垬鏂楁敮鎸佹案涔呯壒鏉冭烦杩�
+        int passRound = BattleManager.Instance.defaultPassRound;
         var name = battleField.ToString();
-        bool isStoryBossBattleField = name == "StoryBossBattleField";
+        
+        // 妫�鏌ユ槸鍚︿负姘镐箙鐗规潈鍗$帺瀹�
         bool hasForeverPrivilege = InvestModel.Instance.IsInvested(InvestModel.foreverCardType);
-        if (hasForeverPrivilege && !isStoryBossBattleField)
+
+        if (hasForeverPrivilege)
         {
-            battleField.ForceFinish();
-            return;
+            // 姘镐箙鐗规潈鍗$帺瀹堕�昏緫
+            if (BattleConst.FieldNameToIndex.ContainsKey(name))
+            {
+                int index = BattleConst.FieldNameToIndex[name];
+                if (BattleManager.Instance.foreverPrivilegePassDict.ContainsKey(index))
+                {
+                    passRound = BattleManager.Instance.foreverPrivilegePassDict[index];
+                }
+                else
+                {
+                    // 鏈厤缃殑鎴樺満绫诲瀷锛屼娇鐢ㄦ櫘閫氱帺瀹惰鍒�
+                    if (BattleManager.Instance.passDict.ContainsKey(index))
+                    {
+                        passRound = BattleManager.Instance.passDict[index];
+                    }
+                    // 鍚﹀垯浣跨敤榛樿閰嶇疆
+                }
+            }
+            // 濡傛灉鎴樺満绫诲瀷涓嶅湪 FieldNameToIndex 涓紝浣跨敤榛樿閰嶇疆
+        }
+        else
+        {
+            // 鏅�氱帺瀹堕�昏緫
+            if (BattleConst.FieldNameToIndex.ContainsKey(name))
+            {
+                int index = BattleConst.FieldNameToIndex[name];
+                if (BattleManager.Instance.passDict.ContainsKey(index))
+                {
+                    passRound = BattleManager.Instance.passDict[index];
+                }
+                // 鍚﹀垯浣跨敤榛樿閰嶇疆
+            }
+            // 濡傛灉鎴樺満绫诲瀷涓嶅湪 FieldNameToIndex 涓紝浣跨敤榛樿閰嶇疆
         }
 
-        int passRound = BattleManager.Instance.passRound;
         int nowRound = battleField.round;
         if (nowRound < passRound)
         {
@@ -214,6 +246,9 @@
         battleField.ForceFinish();
     }
 
+
+
+
     /// <summary>
     /// 鏀瑰彉閫熷害
     /// </summary>

--
Gitblit v1.8.0