Browse Source

功能开启

zhaoyang 3 years ago
parent
commit
703f58609f
31 changed files with 441 additions and 19 deletions
  1. 1 0
      FGUIProject/assets/CommonGame/BuyCountUI.xml
  2. 10 0
      FGUIProject/assets/CommonGame/ComFunctionOpen.xml
  3. 10 0
      FGUIProject/assets/CommonGame/FunctionOpenUI.xml
  4. BIN
      FGUIProject/assets/CommonGame/images/js_xiant_1.png
  5. BIN
      FGUIProject/assets/CommonGame/images/js_xinjiesuo.png
  6. BIN
      FGUIProject/assets/CommonGame/imgFunIcon/js_icon_.png
  7. 5 0
      FGUIProject/assets/CommonGame/package.xml
  8. 100 0
      GameClient/Assets/Game/HotUpdate/Data/FunctionOpenDataManager.cs
  9. 11 0
      GameClient/Assets/Game/HotUpdate/Data/FunctionOpenDataManager.cs.meta
  10. 1 0
      GameClient/Assets/Game/HotUpdate/Data/RoleDataManager.cs
  11. 6 3
      GameClient/Assets/Game/HotUpdate/Data/StoryDataManager.cs
  12. 77 0
      GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/CommonGame/UI_ComFunctionOpen.cs
  13. 11 0
      GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/CommonGame/UI_ComFunctionOpen.cs.meta
  14. 75 0
      GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/CommonGame/UI_FunctionOpenUI.cs
  15. 11 0
      GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/CommonGame/UI_FunctionOpenUI.cs.meta
  16. 1 0
      GameClient/Assets/Game/HotUpdate/Views/ClothingShop/ClothingShopView.cs
  17. 70 0
      GameClient/Assets/Game/HotUpdate/Views/CommonGame/FunctionOpenView.cs
  18. 11 0
      GameClient/Assets/Game/HotUpdate/Views/CommonGame/FunctionOpenView.cs.meta
  19. 3 2
      GameClient/Assets/Game/HotUpdate/Views/Guide/GuideView.cs
  20. 9 2
      GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryController.cs
  21. 2 1
      GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryFightQuicklyView.cs
  22. 2 2
      GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryFightSingleScoreView.cs
  23. 4 3
      GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryFightTargetScoreView.cs
  24. 6 2
      GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryLevelInfoView.cs
  25. 6 1
      GameClient/Assets/Game/HotUpdate/Views/MainStory/StroyFightResultView.cs
  26. 1 3
      GameClient/Assets/Game/HotUpdate/Views/MainUI/MainUIView.cs
  27. 8 0
      GameClient/Assets/Game/HotUpdate/Views/ViewManager.cs
  28. BIN
      GameClient/Assets/ResIn/Config/excelConfig.sqlite.bytes
  29. BIN
      GameClient/Assets/ResIn/UI/CommonGame/CommonGame_atlas0!a.png
  30. BIN
      GameClient/Assets/ResIn/UI/CommonGame/CommonGame_atlas0.png
  31. BIN
      GameClient/Assets/ResIn/UI/CommonGame/CommonGame_fui.bytes

+ 1 - 0
FGUIProject/assets/CommonGame/BuyCountUI.xml

@@ -2,6 +2,7 @@
 <component size="936,536">
   <displayList>
     <image id="n0_hinb" name="bg" src="lwri5u" fileName="imagesExport/hc_kuang_6.png" pkg="mk0fwx0x" xy="0,0" size="936,536"/>
+    <loader id="n26_eiwu" name="n26" xy="0,0" size="936,536" visible="false" url="ui://mk0fwx0xlwri5u" fill="scaleFree"/>
     <component id="n23_ai2z" name="btnAll" src="ai2z9f" fileName="components/Button12.xml" xy="731,131"/>
     <image id="n19_ai2z" name="n19" src="ai2z9e" fileName="imagesExport/hb_kuangdi_2.png" xy="69,237" group="n21_ai2z"/>
     <loader id="n4_hinb" name="icon" xy="101,66" size="200,200" group="n21_ai2z" aspect="true"/>

+ 10 - 0
FGUIProject/assets/CommonGame/ComFunctionOpen.xml

@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="utf-8"?>
+<component size="482,482">
+  <displayList>
+    <image id="n0_g3nf" name="n0" src="g3nf9s" fileName="images/js_xinjiesuo.png" xy="0,0"/>
+    <image id="n1_g3nf" name="n1" src="g3nf9u" fileName="images/js_xiant_1.png" xy="84,130"/>
+    <loader id="n2_g3nf" name="logIcon" xy="161,187" size="160,160" autoSize="true"/>
+    <text id="n3_g3nf" name="txtTitle" xy="173,60" size="136,59" fontSize="44" color="#aa8e46" align="center" text="新解锁"/>
+    <text id="n4_g3nf" name="txtName" xy="185,360" pivot="0.5,0" size="112,49" fontSize="36" color="#aa8e46" align="center" text="新解锁"/>
+  </displayList>
+</component>

+ 10 - 0
FGUIProject/assets/CommonGame/FunctionOpenUI.xml

@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="utf-8"?>
+<component size="482,482">
+  <displayList>
+    <component id="n0_g3nf" name="ComFunctionOpen" src="eiwu9v" fileName="ComFunctionOpen.xml" xy="0,0" pivot="0.5,0.5"/>
+  </displayList>
+  <transition name="t0">
+    <item time="0" type="Scale" target="n0_g3nf" tween="true" startValue="0,0" endValue="1,1" duration="3" ease="Linear"/>
+    <item time="21" type="Scale" target="n0_g3nf" tween="true" startValue="1,1" endValue="0,0" duration="3" ease="Linear"/>
+  </transition>
+</component>

BIN
FGUIProject/assets/CommonGame/images/js_xiant_1.png


BIN
FGUIProject/assets/CommonGame/images/js_xinjiesuo.png


BIN
FGUIProject/assets/CommonGame/imgFunIcon/js_icon_.png


+ 5 - 0
FGUIProject/assets/CommonGame/package.xml

@@ -160,6 +160,11 @@
     <image id="pzq19p" name="cj_hd_xin.png" path="/imagesExport/"/>
     <image id="nz0ts" name="sc_anniu_1(1).png" path="/imagesExport/"/>
     <image id="g3nf9q" name="jinbi_1.png" path="/imagesExport/"/>
+    <component id="g3nf9r" name="FunctionOpenUI.xml" path="/" exported="true"/>
+    <image id="g3nf9s" name="js_xinjiesuo.png" path="/images/"/>
+    <image id="g3nf9t" name="js_icon_.png" path="/imgFunIcon/" exported="true"/>
+    <image id="g3nf9u" name="js_xiant_1.png" path="/images/"/>
+    <component id="eiwu9v" name="ComFunctionOpen.xml" path="/"/>
   </resources>
   <publish name="" path="..\GameClient\Assets\ResIn\UI\CommonGame" packageCount="2" genCode="true" extractAlpha="true"/>
 </packageDescription>

+ 100 - 0
GameClient/Assets/Game/HotUpdate/Data/FunctionOpenDataManager.cs

@@ -0,0 +1,100 @@
+using System.Collections.Generic;
+using UnityEngine;
+
+namespace GFGGame
+{
+    public class FunctionOpenDataManager : SingletonBase<FunctionOpenDataManager>
+    {
+        /// <summary>
+        /// 根据功能名检测功能是否开启
+        /// </summary>
+        /// <param name="viewName"></param>
+        /// <returns></returns>
+        public bool CheckIsFunOpenBgViewName(string viewName)
+        {
+            FunctionOpenCfg cfg = FunctionOpenCfgArray.Instance.GetCfg(viewName);
+            if (cfg == null)
+            {
+                // Debug.LogWarning("g功能.xlsx  功能开启_FunctionOpenCfg  未添加  " + viewName + "  的配置");
+                return true;//未配置功能开启的暂时默认开启
+            }
+            if (cfg.parentId != null && cfg.parentId != "")
+            {
+                //先检查父功能是否开启
+                CheckIsFunOpenBgViewName(cfg.parentId);
+            }
+            if (!CheckIsChapterFunOpen(cfg)) return false;
+            if (!CheckIsLvFunOpen(cfg)) return false;
+
+            return true;
+        }
+
+        /// <summary>
+        /// 根据章节Id检测是否有新功能开启
+        /// </summary>
+        public void CheckHasChapterFunOpen(int chapterId, int level)
+        {
+            FunctionOpenCfg[] cfgs = FunctionOpenCfgArray.Instance.dataArray;
+            List<string> listCfg = new List<string>();
+            for (int i = 0; i < cfgs.Length; i++)
+            {
+                if (cfgs[i].show == 0) continue;
+                if (cfgs[i].chapterId != chapterId || cfgs[i].level != level || !CheckIsChapterFunOpen(cfgs[i], false)) continue;
+                if (!CheckIsLvFunOpen(cfgs[i], false)) continue;
+                listCfg.Add(cfgs[i].id);
+            }
+            if (listCfg.Count > 0)
+            {
+                ViewManager.Show<FunctionOpenView>(listCfg);
+            }
+        }
+        /// <summary>
+        /// 根据角色Lv检测是否有新功能开启
+        /// </summary>
+        public void CheckHasLvFunOpen(int lv)
+        {
+            FunctionOpenCfg[] cfgs = FunctionOpenCfgArray.Instance.dataArray;
+            List<string> listCfg = new List<string>();
+            for (int i = 0; i < cfgs.Length; i++)
+            {
+                if (cfgs[i].show == 0) continue;
+                if (lv != cfgs[i].lv || !CheckIsLvFunOpen(cfgs[i], false)) continue;
+                if (!CheckIsChapterFunOpen(cfgs[i], false)) continue;
+                listCfg.Add(cfgs[i].id);
+            }
+            if (listCfg.Count > 0)
+            {
+                ViewManager.Show<FunctionOpenView>(listCfg);
+            }
+        }
+
+
+        //检测配置章节是否开启
+        private bool CheckIsChapterFunOpen(FunctionOpenCfg cfg, bool showTips = true)
+        {
+
+            if (cfg.chapterId > 0 && cfg.level <= 0 || cfg.level > 0 && cfg.chapterId <= 0)
+            {
+                if (showTips) PromptController.Instance.ShowFloatTextPrompt("功能暂未开启,敬请期待");
+                return false;
+            }
+            if (cfg.chapterId > 0 && StoryDataManager.CheckLevelPass(cfg.chapterId, cfg.level))
+            {
+                return true;
+            }
+            if (showTips) PromptController.Instance.ShowFloatTextPrompt("功能暂未开启,敬请期待");
+            return false;
+        }
+
+        //检测配置角色是否开启
+        private bool CheckIsLvFunOpen(FunctionOpenCfg cfg, bool showTips = true)
+        {
+            if (RoleDataManager.lvl >= cfg.lv)
+            {
+                return true;
+            }
+            if (showTips) PromptController.Instance.ShowFloatTextPrompt("功能暂未开启,敬请期待");
+            return false;
+        }
+    }
+}

+ 11 - 0
GameClient/Assets/Game/HotUpdate/Data/FunctionOpenDataManager.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: 1a3e219bad8a8a342bb6b0bf9ee74500
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 1 - 0
GameClient/Assets/Game/HotUpdate/Data/RoleDataManager.cs

@@ -96,6 +96,7 @@ namespace GFGGame
                     while (exp >= roleLevelCfg.exp)
                     {
                         lvl++;
+                        FunctionOpenDataManager.Instance.CheckHasLvFunOpen(lvl);//等级变化要加测是否有功能开启
                         exp -= roleLevelCfg.exp;
                         roleLevelCfg = RoleLevelCfgArray.Instance.GetCfg(lvl);
                     }

+ 6 - 3
GameClient/Assets/Game/HotUpdate/Data/StoryDataManager.cs

@@ -14,8 +14,8 @@ namespace GFGGame
         public static int currentScoreType;
         public static int currentCardId;
         public static bool usedRecommend;
-        private static int _passChapter = 0;
-        private static int _passLevel = 0;
+        public static int _passChapter = 0;
+        public static int _passLevel = 0;
         private static int _passChapterJY = 10000;
         private static int _passLevelJY = 0;
         private static int _recommendCount = 0;
@@ -393,12 +393,14 @@ namespace GFGGame
             return _passLevel;
         }
 
-        public static List<ItemData> PassCurrentLevel(out bool fistPassLastLvl)
+        public static List<ItemData> PassCurrentLevel(out bool fistPassLastLvl, out bool curLvfirstPass)
         {
             fistPassLastLvl = false;
+            curLvfirstPass = false;
             List<ItemData> currentBonusList = new List<ItemData>();
             if (!CheckCurrentLevelPass())
             {
+                curLvfirstPass = true;
                 int tempPassLevel = currentLevel;
                 int tempPassChapter = GetPassChapter(currentChapter);
                 int nextLevel = currentLevel + 1;
@@ -411,6 +413,7 @@ namespace GFGGame
                     fistPassLastLvl = true;
                 }
                 SetPassData(tempPassChapter, tempPassLevel);
+                // FunctionOpenDataManager.Instance.CheckHasChapterFunOpen(_passChapter + 1, _passLevel);//首次通过要检查是否有功能开启
                 GameProxy.ReqUpdateStoryProgress(_passChapter, _passLevel, _passChapterJY, _passLevelJY);
                 currentBonusList = StoryBonusDataCache.GetBonusList(currentLevelID, true, true);
             }

+ 77 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/CommonGame/UI_ComFunctionOpen.cs

@@ -0,0 +1,77 @@
+/** This is an automatically generated class by FairyGUI. Please do not modify it. **/
+
+using FairyGUI;
+
+namespace UI.CommonGame
+{
+    public partial class UI_ComFunctionOpen
+    {
+        public GComponent target;
+        public GLoader m_logIcon;
+        public GTextField m_txtTitle;
+        public GTextField m_txtName;
+        public const string URL = "ui://eg2y0ldpeiwu9v";
+        public const string PACKAGE_NAME = "CommonGame";
+        public const string RES_NAME = "ComFunctionOpen";
+        private static UI_ComFunctionOpen _proxy;
+
+        public static UI_ComFunctionOpen Create(GObject gObject = null)
+        {
+            var ui = new UI_ComFunctionOpen();
+            if(gObject == null)
+            	ui.target =  (GComponent)UIPackage.CreateObject(PACKAGE_NAME, RES_NAME);
+            else
+            	ui.target =  (GComponent)gObject;
+            ui.Init(ui.target);
+            return ui;
+        }
+
+        public static UI_ComFunctionOpen Proxy(GObject gObject = null)
+        {
+            if(_proxy == null)
+            {
+                _proxy = new UI_ComFunctionOpen();
+            }
+            var ui = _proxy;
+            if(gObject == null)
+            	ui.target =  (GComponent)UIPackage.CreateObject(PACKAGE_NAME, RES_NAME);
+            else
+            	ui.target =  (GComponent)gObject;
+            ui.Init(ui.target);
+            return ui;
+        }
+
+        public static void ProxyEnd()
+        {
+            if (_proxy != null)
+            {
+                _proxy.Dispose();
+            }
+        }
+
+        public static void ClearProxy()
+        {
+            ProxyEnd();
+            _proxy = null;
+        }
+
+        private void Init(GComponent comp)
+        {
+            m_logIcon = (GLoader)comp.GetChild("logIcon");
+            m_txtTitle = (GTextField)comp.GetChild("txtTitle");
+            m_txtName = (GTextField)comp.GetChild("txtName");
+        }
+        public void Dispose(bool disposeTarget = false)
+        {
+            m_logIcon = null;
+            m_txtTitle = null;
+            m_txtName = null;
+            if(disposeTarget && target != null)
+            {
+                target.RemoveFromParent();
+                target.Dispose();
+            }
+            target = null;
+        }
+    }
+}

+ 11 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/CommonGame/UI_ComFunctionOpen.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: 446d60702a1de23408acbfeeee3502fc
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 75 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/CommonGame/UI_FunctionOpenUI.cs

@@ -0,0 +1,75 @@
+/** This is an automatically generated class by FairyGUI. Please do not modify it. **/
+
+using FairyGUI;
+
+namespace UI.CommonGame
+{
+    public partial class UI_FunctionOpenUI
+    {
+        public GComponent target;
+        public UI_ComFunctionOpen m_ComFunctionOpen;
+        public Transition m_t0;
+        public const string URL = "ui://eg2y0ldpg3nf9r";
+        public const string PACKAGE_NAME = "CommonGame";
+        public const string RES_NAME = "FunctionOpenUI";
+        private static UI_FunctionOpenUI _proxy;
+
+        public static UI_FunctionOpenUI Create(GObject gObject = null)
+        {
+            var ui = new UI_FunctionOpenUI();
+            if(gObject == null)
+            	ui.target =  (GComponent)UIPackage.CreateObject(PACKAGE_NAME, RES_NAME);
+            else
+            	ui.target =  (GComponent)gObject;
+            ui.Init(ui.target);
+            return ui;
+        }
+
+        public static UI_FunctionOpenUI Proxy(GObject gObject = null)
+        {
+            if(_proxy == null)
+            {
+                _proxy = new UI_FunctionOpenUI();
+            }
+            var ui = _proxy;
+            if(gObject == null)
+            	ui.target =  (GComponent)UIPackage.CreateObject(PACKAGE_NAME, RES_NAME);
+            else
+            	ui.target =  (GComponent)gObject;
+            ui.Init(ui.target);
+            return ui;
+        }
+
+        public static void ProxyEnd()
+        {
+            if (_proxy != null)
+            {
+                _proxy.Dispose();
+            }
+        }
+
+        public static void ClearProxy()
+        {
+            ProxyEnd();
+            _proxy = null;
+        }
+
+        private void Init(GComponent comp)
+        {
+            m_ComFunctionOpen = (UI_ComFunctionOpen)UI_ComFunctionOpen.Create(comp.GetChild("ComFunctionOpen"));
+            m_t0 = comp.GetTransition("t0");
+        }
+        public void Dispose(bool disposeTarget = false)
+        {
+            m_ComFunctionOpen.Dispose();
+            m_ComFunctionOpen = null;
+            m_t0 = null;
+            if(disposeTarget && target != null)
+            {
+                target.RemoveFromParent();
+                target.Dispose();
+            }
+            target = null;
+        }
+    }
+}

+ 11 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/CommonGame/UI_FunctionOpenUI.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: f2f531e278d82f64bad6f13689887eb4
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 1 - 0
GameClient/Assets/Game/HotUpdate/Views/ClothingShop/ClothingShopView.cs

@@ -185,6 +185,7 @@ namespace GFGGame
 
         private void OnclickBtnBuy()
         {
+            GuideController.HideGuide();
             BuyItemConteoller.Show(_cfgSelected.itemID, _cfgSelected.costID, INIT_COUNT, _cfgSelected.costNum, INIT_COUNT, null, true, false, MAX_COUNT);
 
         }

+ 70 - 0
GameClient/Assets/Game/HotUpdate/Views/CommonGame/FunctionOpenView.cs

@@ -0,0 +1,70 @@
+using UnityEngine;
+using FairyGUI;
+using UI.CommonGame;
+using System.Collections.Generic;
+
+namespace GFGGame
+{
+    public class FunctionOpenView : BaseWindow
+    {
+        private UI_FunctionOpenUI _ui;
+        List<string> _funList = new List<string>();
+
+        public override void Dispose()
+        {
+            base.Dispose();
+        }
+
+        protected override void OnInit()
+        {
+            base.OnInit();
+            packageName = UI_FunctionOpenUI.PACKAGE_NAME;
+            _ui = UI_FunctionOpenUI.Create();
+            this.viewCom = _ui.target;
+            isfullScreen = true;
+            this.viewCom.Center();
+
+        }
+
+        protected override void OnShown()
+        {
+            base.OnShown();
+            List<string> funList = (viewData as object) as List<string>;
+            AddFunDatas(funList);
+            UpdateFunIcon();
+            // _ui.m_t0.Play(UpdateFunIcon);
+            // Timers.inst.Remove(UpdateFunIcon);
+            // Timers.inst.Add(1.5f, _funList.Count, UpdateFunIcon);
+        }
+
+        private void AddFunDatas(List<string> itemList)
+        {
+            for (int i = 0; i < itemList.Count; i++)
+            {
+                if (_funList.IndexOf(itemList[i]) < 0)
+                {
+                    _funList.Add(itemList[i]);
+                }
+            }
+        }
+        private void UpdateFunIcon()
+        {
+            if (_funList.Count == 0)
+            {
+                this.Hide();
+                return;
+            }
+            FunctionOpenCfg cfg = FunctionOpenCfgArray.Instance.GetCfg(_funList[0]);
+            _ui.m_ComFunctionOpen.m_txtName.text = cfg.name;
+            _ui.m_ComFunctionOpen.m_logIcon.url = ResPathUtil.GetCommonGameResPath(cfg.res);
+            _funList.RemoveAt(0);
+            _ui.m_t0.Play(UpdateFunIcon);
+        }
+
+        protected override void OnHide()
+        {
+            base.OnHide();
+        }
+
+    }
+}

+ 11 - 0
GameClient/Assets/Game/HotUpdate/Views/CommonGame/FunctionOpenView.cs.meta

@@ -0,0 +1,11 @@
+fileFormatVersion: 2
+guid: 9692fd8d862dc8146b3d7e0498d3120a
+MonoImporter:
+  externalObjects: {}
+  serializedVersion: 2
+  defaultReferences: []
+  executionOrder: 0
+  icon: {instanceID: 0}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 3 - 2
GameClient/Assets/Game/HotUpdate/Views/Guide/GuideView.cs

@@ -6,7 +6,7 @@ using System;
 
 namespace GFGGame
 {
-    public class GuideView : BaseWindow
+    public class GuideView : BaseView
     {
         private UI_GuideUI _ui;
         private bool _needUpdate;
@@ -26,7 +26,8 @@ namespace GFGGame
             packageName = UI_GuideUI.PACKAGE_NAME;
             _ui = UI_GuideUI.Create();
             this.viewCom = _ui.target;
-            this.clickBlankToClose = false;
+            // this.clickBlankToClose = false;
+            this.layer = ConstViewLayer.TOP;
             isfullScreen = true;
             _ui.m_rectFrame.target.AddRelation(_ui.m_mask.m_guideArea, RelationType.Width);
             _ui.m_rectFrame.target.AddRelation(_ui.m_mask.m_guideArea, RelationType.Height);

+ 9 - 2
GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryController.cs

@@ -29,11 +29,14 @@ namespace GFGGame
 
         private static void OnCompleteChapterStoryDialog(bool isSkip, object param)
         {
+
             List<ItemData> bonusList = null;
             bool _fistPassLastLvl = false;
+            bool _curLvfirstPass = false;
             if (!isSkip)
             {
-                bonusList = StoryDataManager.PassCurrentLevel(out _fistPassLastLvl);
+
+                bonusList = StoryDataManager.PassCurrentLevel(out _fistPassLastLvl, out _curLvfirstPass);
             }
             if (_fistPassLastLvl)
             {
@@ -43,6 +46,10 @@ namespace GFGGame
             {
                 ViewManager.Show(ViewName.STORY_CHAPTER_VIEW, StoryDataManager.currentChapter, null, true);
             }
+            if (_curLvfirstPass)
+            {
+                FunctionOpenDataManager.Instance.CheckHasChapterFunOpen(StoryDataManager._passChapter + 1, StoryDataManager._passLevel);//首次通过要检查是否有功能开启
+            }
             if (bonusList != null && bonusList.Count > 0)
             {
                 ViewManager.Show(ViewName.GET_BONUS_VIEW, bonusList);
@@ -53,7 +60,7 @@ namespace GFGGame
         private static void OnCompleteCardStoryDialog(bool isSkip, object param)
         {
             CardData cardData = param as CardData;
-            ViewManager.Show(ViewName.CARD_FOSTER_VIEW, cardData, new object[] { ViewName.CARD_DETAIL_VIEW}, true);
+            ViewManager.Show(ViewName.CARD_FOSTER_VIEW, cardData, new object[] { ViewName.CARD_DETAIL_VIEW }, true);
             ViewManager.Show(ViewName.CARD_STORY_VIEW, cardData);
         }
     }

+ 2 - 1
GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryFightQuicklyView.cs

@@ -79,7 +79,8 @@ namespace GFGGame
             for (int i = 1; i <= count; i++)
             {
                 bool fistPassLastLvl = false;
-                List<ItemData> bonusList = StoryDataManager.PassCurrentLevel(out fistPassLastLvl);
+                bool curLvfirstPass = false;
+                List<ItemData> bonusList = StoryDataManager.PassCurrentLevel(out fistPassLastLvl, out curLvfirstPass);
                 _totalBonusList.Add(bonusList);
             }
             _index = 0;

+ 2 - 2
GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryFightSingleScoreView.cs

@@ -29,7 +29,6 @@ namespace GFGGame
             isfullScreen = true;
 
             _scenePrefab = GFGAsset.Load<GameObject>(ResPathUtil.GetPrefabPath("SceneFightSingleScore"));
-            EventAgent.AddEventListener(ConstMessage.CARD_SKILL, CircleScoreStart);
         }
 
         protected override void OnShown()
@@ -37,6 +36,7 @@ namespace GFGGame
             base.OnShown();
             if (_sceneObject == null) _sceneObject = GameObject.Instantiate(_scenePrefab);
             SceneController.UpdateRole(EquipDataCache.cacher.equipDatas, _sceneObject);
+            EventAgent.AddEventListener(ConstMessage.CARD_SKILL, CircleScoreStart);
 
             _ui.m_comClickCircle.m_loaCircle.onClick.Add(CircleScoreEnd);
             _ui.m_comAllCircle.target.onTouchBegin.Add(OnComAllCircleClickBegin);
@@ -226,6 +226,7 @@ namespace GFGGame
 
         private void Skip(object param = null)
         {
+            EventAgent.RemoveEventListener(ConstMessage.CARD_SKILL, CircleScoreStart);
             Timers.inst.Remove(SkillScoreStart);
             Timers.inst.Remove(Skip);
             this.Hide();
@@ -240,7 +241,6 @@ namespace GFGGame
                 GameObject.Destroy(_sceneObject);
                 _sceneObject = null;
             }
-            EventAgent.RemoveEventListener(ConstMessage.CARD_SKILL, CircleScoreStart);
 
         }
 

+ 4 - 3
GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryFightTargetScoreView.cs

@@ -65,7 +65,6 @@ namespace GFGGame
                 icon.onClick.Add(() => { OnBtnSkillClick(btnSkill); });
             }
             _ui.m_btnBack.onClick.Add(OnBtnBackClick);
-            EventAgent.AddEventListener(ConstMessage.CARD_SKILL, UpdateCircleResult);
 
         }
 
@@ -98,6 +97,8 @@ namespace GFGGame
             {
                 _sceneObject = GameObject.Instantiate(_scenePrefab);
             }
+            EventAgent.AddEventListener(ConstMessage.CARD_SKILL, UpdateCircleResult);
+
             SceneController.UpdateRole(EquipDataCache.cacher.equipDatas, _sceneObject);
             StoryLevelCfg levelCfg = StoryLevelCfgArray.Instance.GetCfg(StoryDataManager.currentLevelID);
             StoryFightCfg fightCfg = StoryFightCfgArray.Instance.GetCfg(levelCfg.fightID);
@@ -426,13 +427,13 @@ namespace GFGGame
                 _sceneObject = null;
             }
             _npcSkillDic.Clear();
-            EventAgent.RemoveEventListener(ConstMessage.CARD_SKILL, CircleScoreStart);
+
 
         }
 
         private void Skip(object param = null)
         {
-
+            EventAgent.RemoveEventListener(ConstMessage.CARD_SKILL, CircleScoreStart);
             Reset();
             this.Hide();
             ViewManager.Show(ViewName.STORY_FIGHT_RESULT_VIEW);

+ 6 - 2
GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryLevelInfoView.cs

@@ -60,7 +60,11 @@ namespace GFGGame
             base.OnHide();
             EventAgent.RemoveEventListener(ConstMessage.ROLE_POWER_CHANGED, UpdateBtnFightTimes);
             Timers.inst.Remove(UpdateToCheckGuide);
-            // GuideController.HideGuide();
+
+            if (GuideDataManager.currentGuideId == ConstGuideId.SUIT_SYNTHETIC_GUIDE)
+            {
+                GuideController.HideGuide();
+            }
             GuideController.TryCompleteGuide(ConstGuideId.TIPS_TAGS_FIGHT);
         }
 
@@ -198,7 +202,7 @@ namespace GFGGame
                 string scoreStr = "" + score;
                 if (score <= fightCfg.score1)
                 {
-                    scoreStr = "[color=#fddadb]失败 " + scoreStr + "[/color]";
+                    scoreStr = "[color=#A28D77]失败 " + scoreStr + "[/color]";
                 }
                 _ui.m_txtHighestScore.text = scoreStr;
                 _ui.m_flower.target.visible = true;

+ 6 - 1
GameClient/Assets/Game/HotUpdate/Views/MainStory/StroyFightResultView.cs

@@ -12,6 +12,7 @@ namespace GFGGame
         private GameObject _scenePrefab;
         private List<ItemData> _currentBonusList;
         private bool _fistPassLastLvl;
+        private bool _curLvfirstPass = false;
 
         public override void Dispose()
         {
@@ -86,7 +87,11 @@ namespace GFGGame
                 _ui.m_btnClose.enabled = false;
                 //过关
                 _ui.m_expBar.m_txtLvlAdded.text = "" + fightCfg.exp;
-                _currentBonusList = StoryDataManager.PassCurrentLevel(out _fistPassLastLvl);
+                _currentBonusList = StoryDataManager.PassCurrentLevel(out _fistPassLastLvl, out _curLvfirstPass);
+                if (_curLvfirstPass)
+                {
+                    FunctionOpenDataManager.Instance.CheckHasChapterFunOpen(StoryDataManager._passChapter + 1, StoryDataManager._passLevel);//首次通过要检查是否有功能开启
+                }
                 Timers.inst.Add(0.5f, 1, AddExp);
             }
             _ui.m_selfScore.m_txtScore.textFormat = tf;

+ 1 - 3
GameClient/Assets/Game/HotUpdate/Views/MainUI/MainUIView.cs

@@ -229,13 +229,11 @@ namespace GFGGame
             Timers.inst.Add(effectTime, 1, (param) =>
             {
                 _ui.m_btnCiPai.m_holder1.visible = false;
-                //Timers.inst.AddUpdate(UpdateToCheckGuide);
-                // ViewManager.Show(ViewName.CARD_VIEW, null, new object[] { ViewName.MAINUI_VIEW, this.viewData });
+
                 ViewManager.Show(ViewName.CARD_DETAIL_VIEW, null, new object[] { ViewName.MAINUI_VIEW, this.viewData });
                 isOpen = false;
 
             });
-
         }
 
 

+ 8 - 0
GameClient/Assets/Game/HotUpdate/Views/ViewManager.cs

@@ -56,6 +56,10 @@ namespace GFGGame
                 HideAllView(viewName);
             }
             UIView obj = null;
+            if (!FunctionOpenDataManager.Instance.CheckIsFunOpenBgViewName(viewName))
+            {
+                return;
+            }
             if (_viewDic.ContainsKey(viewName))
             {
                 obj = _viewDic[viewName];
@@ -96,6 +100,10 @@ namespace GFGGame
         public static void Show<T>(object viewData = null, object[] goBackParams = null, bool hideOthers = false, bool resetGobackParams = false) where T : class, new()
         {
             string viewName = typeof(T).FullName;
+            if (!FunctionOpenDataManager.Instance.CheckIsFunOpenBgViewName(viewName))
+            {
+                return;
+            }
             if (hideOthers)
             {
                 HideAllView(viewName);

BIN
GameClient/Assets/ResIn/Config/excelConfig.sqlite.bytes


BIN
GameClient/Assets/ResIn/UI/CommonGame/CommonGame_atlas0!a.png


BIN
GameClient/Assets/ResIn/UI/CommonGame/CommonGame_atlas0.png


BIN
GameClient/Assets/ResIn/UI/CommonGame/CommonGame_fui.bytes