Browse Source

Merge branch 'master' of http://10.108.64.190:3000/gfg/client

guodong 2 years ago
parent
commit
78cd6ceb23
24 changed files with 102 additions and 57 deletions
  1. 1 1
      FGUIProject/assets/CommonGame/components/BtnStyle006.xml
  2. BIN
      FGUIProject/assets/CommonGame/imagesExport/kp_kuang_1.png
  3. BIN
      FGUIProject/assets/CommonGame/imagesExport/kp_kuang_2.png
  4. 2 2
      FGUIProject/assets/CommonGame/package.xml
  5. 1 1
      FGUIProject/assets/LuckyBox/combox/ComBox1.xml
  6. 3 1
      FGUIProject/assets/Main/components/ComAllPerfect.xml
  7. 42 0
      GameClient/Assets/Game/HotUpdate/Data/RedDotDataManager.cs
  8. 6 7
      GameClient/Assets/Game/HotUpdate/DressUp/SceneController.cs
  9. 1 1
      GameClient/Assets/Game/HotUpdate/Views/ClothingSynthetic/ClothingSyntheticView.cs
  10. 1 1
      GameClient/Assets/Game/HotUpdate/Views/ClothingSynthetic/SuitSyntheticView.cs
  11. 9 9
      GameClient/Assets/Game/HotUpdate/Views/Common/Controller/LuckyBoxController.cs
  12. 6 0
      GameClient/Assets/Game/HotUpdate/Views/Common/Controller/ValueBarController.cs
  13. 1 1
      GameClient/Assets/Game/HotUpdate/Views/CommonGame/ApproachView.cs
  14. 7 2
      GameClient/Assets/Game/HotUpdate/Views/EnduringGiftBox/EnduringGiftBoxView.cs
  15. 1 22
      GameClient/Assets/Game/HotUpdate/Views/LuckyBox/LuckyBoxView.cs
  16. 5 3
      GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryFightFailView.cs
  17. 2 1
      GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryFightSingleScoreView.cs
  18. 3 0
      GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryFightTargetScoreView.cs
  19. 7 5
      GameClient/Assets/Game/HotUpdate/Views/MainStory/StroyFightResultView.cs
  20. 1 0
      GameClient/Assets/Game/HotUpdate/Views/MainUI/MainUIView.cs
  21. 3 0
      GameClient/Assets/Game/HotUpdate/Views/ViewManager.cs
  22. BIN
      GameClient/Assets/ResIn/UI/CommonGame/CommonGame_fui.bytes
  23. BIN
      GameClient/Assets/ResIn/UI/LuckyBox/LuckyBox_fui.bytes
  24. BIN
      GameClient/Assets/ResIn/UI/Main/Main_fui.bytes

+ 1 - 1
FGUIProject/assets/CommonGame/components/BtnStyle006.xml

@@ -8,7 +8,7 @@
     <text id="n1_9qpb" name="title" xy="0,0" size="316,94" font="ui://eg2y0ldpa0cftks" fontSize="46" color="#5a3e16" align="center" vAlign="middle" autoSize="none" singleLine="true" text="">
       <relation target="" sidePair="width-width,height-height,center-center,middle-middle"/>
     </text>
-    <graph id="n3_e050" name="holder" xy="158,51" size="10,10" type="rect"/>
+    <graph id="n3_e050" name="holder" xy="158,51" size="10,10"/>
   </displayList>
   <Button/>
   <relation target="n2_idkd" sidePair="width-width,height-height"/>

BIN
FGUIProject/assets/CommonGame/imagesExport/kp_kuang_1.png


BIN
FGUIProject/assets/CommonGame/imagesExport/kp_kuang_2.png


+ 2 - 2
FGUIProject/assets/CommonGame/package.xml

@@ -363,8 +363,8 @@
     <image id="e050to7" name="tb_yajizijin.png" path="/imgItemIcon/" exported="true"/>
     <image id="e050to8" name="tb_zhizaoli.png" path="/imgItemIcon/" exported="true"/>
     <component id="e050tob" name="Component2.xml" path="/componentsBg/"/>
-    <image id="94m19v" name="kp_kuang_1.png" path="/imagesExport/" exported="true" scale="9grid" scale9grid="40,110,51,220"/>
-    <image id="94m19u" name="kp_kuang_2.png" path="/imagesExport/" exported="true" scale="9grid" scale9grid="39,110,61,220"/>
+    <image id="94m19v" name="kp_kuang_2.png" path="/imagesExport/" exported="true" scale="9grid" scale9grid="40,110,51,220"/>
+    <image id="94m19u" name="kp_kuang_1.png" path="/imagesExport/" exported="true" scale="9grid" scale9grid="39,110,61,220"/>
     <image id="94m19t" name="kp_kuang_4.png" path="/imagesExport/" exported="true" scale="9grid" scale9grid="38,110,53,220"/>
     <image id="94m19w" name="kp_kuang_3.png" path="/imagesExport/" exported="true" scale="9grid" scale9grid="44,110,54,220"/>
     <image id="ofwutoc" name="card_jn_db.png" path="/imagesNew/" exported="true"/>

+ 1 - 1
FGUIProject/assets/LuckyBox/combox/ComBox1.xml

@@ -42,7 +42,7 @@
       <relation target="" sidePair="center-center"/>
     </text>
     <image id="n59_vols" name="imgSpecial" src="volstbn" fileName="imageNews/bt_jiaobiao_bichu.png" xy="865,1623" group="n84_e050"/>
-    <graph id="n83_e050" name="holder" xy="919,1675" size="10,10" group="n84_e050" type="rect"/>
+    <graph id="n83_e050" name="holder" xy="919,1675" size="10,10" group="n84_e050"/>
     <group id="n84_e050" name="grpSpecial" xy="865,1623" size="112,123" group="n61_vols" advanced="true">
       <relation target="n58_vols" sidePair="right-right,top-top"/>
     </group>

+ 3 - 1
FGUIProject/assets/Main/components/ComAllPerfect.xml

@@ -28,7 +28,7 @@
     <item time="0" type="Visible" target="n47_fqor" value="false"/>
     <item time="3" type="Visible" target="n47_fqor" value="true"/>
     <item time="6" type="Visible" target="n43_gfx4" value="true"/>
-    <item time="36" type="Visible" target="n43_gfx4" value="true"/>
+    <item time="36" type="Visible" target="n38_qgxy" value="false"/>
   </transition>
   <transition name="t1">
     <item time="0" type="Visible" target="n43_gfx4" value="false"/>
@@ -36,11 +36,13 @@
     <item time="72" type="Visible" target="n43_gfx4" value="false"/>
   </transition>
   <transition name="t2">
+    <item time="0" type="Visible" target="n43_gfx4" value="false"/>
     <item time="0" type="Visible" target="n44_gfx4" value="false"/>
     <item time="0" type="Visible" target="n45_gfx4" value="true"/>
     <item time="0" type="Visible" target="n47_fqor" value="true"/>
     <item time="18" type="Scale" target="n38_qgxy" tween="true" startValue="1,1" endValue="1.3,1.3" duration="5" ease="Linear"/>
     <item time="18" type="Visible" target="n38_qgxy" value="true"/>
+    <item time="18" type="Visible" target="n43_gfx4" value="false"/>
     <item time="23" type="Scale" target="n38_qgxy" tween="true" startValue="1.3,1.3" endValue="1,1" duration="5" ease="Linear"/>
     <item time="28" type="Scale" target="n38_qgxy" tween="true" startValue="1,1" endValue="1,1" duration="26" ease="Linear"/>
     <item time="36" type="Visible" target="n45_gfx4" value="false"/>

+ 42 - 0
GameClient/Assets/Game/HotUpdate/Data/RedDotDataManager.cs

@@ -808,5 +808,47 @@ namespace GFGGame
             }
             return false;
         }
+
+        /// <summary>
+        /// 常驻礼包是否有需要领取的金币
+        /// </summary>
+        /// <returns></returns>
+        public bool GetGoldRed()
+        {
+            var shopCfgList = ShopCfgArray.Instance
+                .GetCfgsBymenu1Andmenu2(ConstStoreTabId.ENDURING_GIFT_BOX, ConstStoreSubId.ENDURING_GIFT_BOX_GOLD)
+                .OrderBy(a => a.refreshType).ToList();
+            foreach (var shopCfg in shopCfgList)
+            {
+                var weekGiftBoxState = EnduringGiftBoxDataManager.Instance.DayIsRebateGiftBox(shopCfg.itemId);
+                if (weekGiftBoxState)
+                {
+                    return true;
+                }
+            }
+
+            return false;
+        }
+        
+        /// <summary>
+        /// 常驻礼包是否有需要领取的体力
+        /// </summary>
+        /// <returns></returns>
+        public bool GetPowerRed()
+        {
+            var shopCfgList = ShopCfgArray.Instance
+                .GetCfgsBymenu1Andmenu2(ConstStoreTabId.ENDURING_GIFT_BOX, ConstStoreSubId.ENDURING_GIFT_BOX_POWER)
+                .OrderBy(a => a.refreshType).ToList();
+            foreach (var shopCfg in shopCfgList)
+            {
+                var weekGiftBoxState = EnduringGiftBoxDataManager.Instance.DayIsRebateGiftBox(shopCfg.itemId);
+                if (weekGiftBoxState)
+                {
+                    return true;
+                }
+            }
+
+            return false;
+        }
     }
 }

+ 6 - 7
GameClient/Assets/Game/HotUpdate/DressUp/SceneController.cs

@@ -119,16 +119,15 @@ namespace GFGGame
             _gameObject = DressUpUtil.CreateAnimationObj(res);
             _gameObject.transform.localScale = new Vector3(scale, scale, scale);
 
-            if (_wrapper == null)
-            {
-                _wrapper = new GoWrapper(_gameObject);
-                holder.SetNativeObject(_wrapper);
-            }
-            else
+            if (_wrapper != null)
             {
                 GameObject.Destroy(_wrapper.wrapTarget);
-                _wrapper.wrapTarget = _gameObject;//替换资源
+                _wrapper.Dispose();
             }
+
+            _wrapper = new GoWrapper(_gameObject);
+            holder.SetNativeObject(_wrapper);
+
             wrapper = _wrapper;
             gameObject = _gameObject;
         }

+ 1 - 1
GameClient/Assets/Game/HotUpdate/Views/ClothingSynthetic/ClothingSyntheticView.cs

@@ -395,7 +395,7 @@ namespace GFGGame
             }
             if (!ViewManager.CheckIsTopView(this.viewCom)) return;
 
-            int itemId = 10016;
+            int itemId = 10506;
             int itemIndex = 0;
             for (int i = 0; i < _ui.m_listClothing.numItems; i++)
             {

+ 1 - 1
GameClient/Assets/Game/HotUpdate/Views/ClothingSynthetic/SuitSyntheticView.cs

@@ -233,7 +233,7 @@ namespace GFGGame
         {
             if (!ViewManager.CheckIsTopView(this.viewCom)) return;
 
-            int suitId = 200004;
+            int suitId = 200041;
             int suitIndex = 0;
             for (int i = 0; i < _suitListIds.Count; i++)
             {

+ 9 - 9
GameClient/Assets/Game/HotUpdate/Views/Common/Controller/LuckyBoxController.cs

@@ -31,7 +31,7 @@ namespace GFGGame
             _curTime = _turnTime;
             _luckyBoxCfg = LuckyBoxCfgArray.Instance.GetCfg(luckyBoxId);
             _com.GetChild("loaMask").asLoader.url = ResPathUtil.GetBgImgPath(_luckyBoxCfg.bgResArr[_bgIndex]);
-            UpdateRes();
+            ChangeRes();
             Timers.inst.Remove(UpdateTime);
             if (_luckyBoxCfg.resArr.Length > 1 || _luckyBoxCfg.suitIdArr.Length > 1)
             {
@@ -52,14 +52,14 @@ namespace GFGGame
                 _modelIndex = _modelIndex + 1 == _luckyBoxCfg.suitIdArr.Length ? 0 : _modelIndex + 1;
             }
 
-            _com.GetTransition("t0").Play(UpdateRes);
+            _com.GetTransition("t0").Play(ChangeRes);
             // ChangeRes();
         }
-        private void UpdateRes()
-        {
-            Timers.inst.StartCoroutine(ChangeRes());
-        }
-        private IEnumerator ChangeRes()
+        // private void UpdateRes()
+        // {
+        //     Timers.inst.StartCoroutine(ChangeRes());
+        // }
+        private void ChangeRes()
         {
             UI_ComModel _comModel = UI_ComModel.Proxy(_com);
             _comModel.m_loaBg.url = ResPathUtil.GetBgImgPath(_luckyBoxCfg.bgResArr[_bgIndex]);
@@ -91,14 +91,14 @@ namespace GFGGame
                 {
                     _comModel.m_loaRes.url = "";
                     _comModel.m_loaMask.alpha = 1;
-                    yield return null;
+                    // yield return null;
                     int scale = _luckyBoxCfg.scaleArr.Length > 0 ? Math.Abs(_luckyBoxCfg.scaleArr[_modelIndex]) / 10000 : 100;
                     _dressUpObjUI.ResetSceneObj(scale, false, false, null, false);
                     _dressUpObjUI.dressUpObj.PutOnSuitCfg(_luckyBoxCfg.suitIdArr[_modelIndex], true, new int[] { ConstDressUpItemType.BEI_JING }, false, false);
                     _dressUpObjUI.UpdateWrapper(_comModel.m_holder);
                     _dressUpObjUI.sceneObject.transform.localScale = new Vector3(direction * scale, scale, scale);
                     _comModel.m_holder.SetPosition(_luckyBoxCfg.posArr[_modelIndex][0], _luckyBoxCfg.posArr[_modelIndex][1], 1);
-                    yield return null;
+                    // yield return null;
                 }
             }
             _comModel.m_t1.Play();

+ 6 - 0
GameClient/Assets/Game/HotUpdate/Views/Common/Controller/ValueBarController.cs

@@ -173,6 +173,12 @@ namespace GFGGame
             _valueBar.m_list.numItems = itemIds.Count;
         }
 
+        public void UpRead()
+        {
+            RedDotController.Instance.SetComRedDot(_valueBar.m_btnPower.target, RedDotDataManager.Instance.GetPowerRed());
+            RedDotController.Instance.SetComRedDot(_valueBar.m_btnGold.target, RedDotDataManager.Instance.GetGoldRed());
+        }
+
         private void RenderListItem(int index, GObject obj)
         {
             int itemId = (obj.parent.data as List<int>)[index];

+ 1 - 1
GameClient/Assets/Game/HotUpdate/Views/CommonGame/ApproachView.cs

@@ -178,7 +178,7 @@ namespace GFGGame
                     int storeSubId = int.Parse(infos[2]);
 
                     isJump = ViewManager.Show<StoreView>(new object[] { storeTabId, storeSubId });
-                    break;
+                    return;
                 // case ConstFunctionId.SHOP_GIFT_BAG:
                 //     // this.Hide();
                 //     int giftBagValue = int.Parse(infos[1]);

+ 7 - 2
GameClient/Assets/Game/HotUpdate/Views/EnduringGiftBox/EnduringGiftBoxView.cs

@@ -294,6 +294,8 @@ namespace GFGGame
 
                 numItems = childItemCfg.param1Arr.Length;
 
+                //领取加红点
+                RedDotController.Instance.SetComRedDot(item.m_btnCurReceive.target, weekGiftBoxState);
                 //是否需要领取
                 if (weekGiftBoxState)
                 {
@@ -376,6 +378,7 @@ namespace GFGGame
                 GuideController.TryCompleteGuideIndex(ConstGuideId.BUY_POWER, 1);
                 GuideController.TryCompleteGuide(ConstGuideId.BUY_POWER, 1);
             }
+
             GObject sender = context.sender as GObject;
             GObject obj = sender.parent;
             ShopCfg cfg = obj.data as ShopCfg;
@@ -549,10 +552,12 @@ namespace GFGGame
             // Dispose();
             this.Hide();
         }
+
         private void CheckGuide()
         {
             Timers.inst.AddUpdate(CheckGuide);
         }
+
         private void CheckGuide(object param)
         {
             if (GuideDataManager.IsGuideFinish(ConstGuideId.BUY_POWER) <= 0)
@@ -570,9 +575,9 @@ namespace GFGGame
             if (!ViewManager.CheckIsTopView(this.viewCom)) return;
             if (_itemId == ConstItemID.POWER)
             {
-                GuideController.TryGuide(_ui.m_list.GetChildAt(1).asCom.GetChild("btnCurReceive").asButton, ConstGuideId.BUY_POWER, 1, "花点小钱可以购买体力超值返利包,每天都能领体力哦~");
+                GuideController.TryGuide(_ui.m_list.GetChildAt(1).asCom.GetChild("btnCurReceive").asButton,
+                    ConstGuideId.BUY_POWER, 1, "花点小钱可以购买体力超值返利包,每天都能领体力哦~");
             }
-
         }
     }
 }

+ 1 - 22
GameClient/Assets/Game/HotUpdate/Views/LuckyBox/LuckyBoxView.cs

@@ -133,46 +133,25 @@ namespace GFGGame
 
             Timers.inst.AddUpdate(CheckGuide);
         }
-        // private string GetListItemResource(int index)
-        // {
-        //     if (index == 0 && _activeBoxId > 0)
-        //     {
-        //         return "UI://LuckyBox/ComBox";
-        //     }
-        //     else
-        //     {
-        //         int boxId = LuckyBoxDataManager.Instance.luckyBoxIds[index];
-        //         return string.Format("UI://LuckyBox/ComBox_{0}", boxId);
-        //     }
-        // }
+
         private void RenderListBgItem(int index, GObject obj)
         {
             int boxId = LuckyBoxDataManager.Instance.luckyBoxIds[index];
-            // LuckyBoxCfg cfg = LuckyBoxCfgArray.Instance.GetCfg(boxId);
-            // LuckyBoxDataManager.Instance.InitData(boxId);
-
-            // UI_ComBox1 comBox = UI_ComBox1.Proxy(obj);
-
 
-            // UI_ComBox1.ProxyEnd();
         }
 
         private void OnBtnLeftClick()
         {
             int index = _curIndex - 1;
-            // _curIndex--;
             index = Mathf.Max(0, index);
             _ui.m_listBg.ScrollToView(index, true);
-            // OnListBgScroll();
         }
 
         private void OnBtnRightClick()
         {
             int index = _curIndex + 1;
-            // _curIndex++;
             index = Mathf.Min(_ui.m_listBg.numItems - 1, index);
             _ui.m_listBg.ScrollToView(index, true);
-            // OnListBgScroll();
         }
 
         private void OnListBgScroll()

+ 5 - 3
GameClient/Assets/Game/HotUpdate/Views/MainStory/StoryFightFailView.cs

@@ -91,9 +91,11 @@ namespace GFGGame
             {
                 param[i] = cfg.jumpParamArr[i];
             }
-            Hide();
-            ViewManager.Hide<StroyFightResultView>();
-            ViewManager.JumpToView(cfg.jumpId, param, null, false);
+            // ViewManager.Hide<StroyFightResultView>();
+
+            ViewManager.JumpToView(cfg.jumpId, param, null);
+            // ViewManager.Show<MainUIView>();
+            //  Hide();
 
         }
     }

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

@@ -341,7 +341,7 @@ namespace GFGGame
         {
             Debug.Log("_partId:" + _partId);
 
-            _ui.m_comClick.target.touchable = false;
+            // _ui.m_comClick.target.touchable = false;
 
             PartScoreResultEnd();
             _partScore = ScoreSystemData.Instance.GetPartScore(roleData, _partId, clickType, _allSkillScore);
@@ -463,6 +463,7 @@ namespace GFGGame
         private void AllCircleScoreEnd()
         {
             if (!_isAllPerfect) return;
+            _ui.m_comClick.target.touchable = false;
             _isAllPerfect = false;
             _ui.m_comClick.m_comAllPerfect.m_t1.Stop(true, false);
             Timers.inst.Remove(ComAllCirclePressTime);

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

@@ -626,15 +626,18 @@ namespace GFGGame
             Timers.inst.Remove(ComAllCirclePressTime);
 
             int allCircleScore = 0;
+            int allRargetCircleScore = 0;
             if (_time >= ConstScoreSystem.LONG_PRESS_TIME / FightDataManager.Instance.fightSpeed || _isAutoPlay)
             {
                 allCircleScore = ScoreSystemData.Instance.GetAllCircleAddScore(_mainScore);
+                allRargetCircleScore = ScoreSystemData.Instance.GetAllCircleAddScore(_mainScore);
             }
             _ui.m_comClick.m_comAllPerfect.m_txtCount.text = allCircleScore.ToString();
             _ui.m_comClick.m_comResult.target.visible = false;
 
             _time = 0;
             _score += allCircleScore;
+            _targetScore += allCircleScore;
             _ui.m_comClick.m_comAllPerfect.m_t2.Play(() =>
                 {
                     _prefectCount = 0;

+ 7 - 5
GameClient/Assets/Game/HotUpdate/Views/MainStory/StroyFightResultView.cs

@@ -149,7 +149,7 @@ namespace GFGGame
             _ui.m_comResult.m_t0.Play(AddExp);
         }
 
-        protected override void OnHide()
+        protected override async void OnHide()
         {
             base.OnHide();
             if (_sceneObject != null)
@@ -161,11 +161,8 @@ namespace GFGGame
             MusicManager.Instance.Play(ResPathUtil.GetMusicPath(ConstMusicName.DEFAULT));
             _ui.m_comResult.m_t1.Play();
             _ui.m_comExpBar.m_proExp.m_comHolder.target.width = 0;
-        }
 
-        private async void OnClickBtnClose(object param)
-        {
-            this.Hide();
+
             if (InstanceZonesDataManager.FightScene == ConstInstanceZonesType.Field)
             {
                 Timers.inst.Remove(OnClickBtnClose);
@@ -195,6 +192,11 @@ namespace GFGGame
             InstanceZonesDataManager.currentCardId = -1;
         }
 
+        private void OnClickBtnClose(object param)
+        {
+            this.Hide();
+        }
+
         private void AddExp()
         {
             float exp = GameGlobal.myNumericComponent.GetAsInt(NumericType.Exp);

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

@@ -1008,6 +1008,7 @@ namespace GFGGame
 
         private void UpdateRedDot()
         {
+            _valueBarController.UpRead();
             RedDotController.Instance.SetComRedDot(_btnGongGao, RedDotDataManager.Instance.GetNoticeRed());
             RedDotController.Instance.SetComRedDot(_btnRenWu, RedDotDataManager.Instance.GetTaskRed());
             // RedDotController.Instance.SetComRedDot(_ui.m_btnDailyLogin.target,

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

@@ -457,6 +457,9 @@ namespace GFGGame
                 case nameof(StoryChapterView):
                     ViewManager.Show<StoryChapterView>(param[0], goBackDatas, hideOther);
                     break;
+                case nameof(FirstChargeBonusView):
+                    ViewManager.Show<FirstChargeBonusView>(param, goBackDatas, false);
+                    break;
                 default:
                     ViewManager.Show($"GFGGame.{jumpId}", null, goBackDatas, hideOther, true);
                     break;

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


BIN
GameClient/Assets/ResIn/UI/LuckyBox/LuckyBox_fui.bytes


BIN
GameClient/Assets/ResIn/UI/Main/Main_fui.bytes