zhaoyang 2 vuotta sitten
vanhempi
commit
0a6524d29a

+ 4 - 4
FGUIProject/assets/LuckyBox/LuckyBoxStarUI.xml

@@ -1,12 +1,12 @@
 <?xml version="1.0" encoding="utf-8"?>
 <component size="1080,1920" designImage="ui://drx9d1usw1qi2n" designImageOffsetY="-240">
-  <controller name="ctrlBuyType" alias="购买类型" pages="0,,1," selected="0">
+  <controller name="ctrlBuyType" alias="购买类型" pages="0,,1," selected="1">
     <remark page="0" value="买一次"/>
     <remark page="1" value="买十次"/>
   </controller>
-  <controller name="ctrlRewardsType" alias="奖池类型" pages="0,,1,,2," selected="0"/>
+  <controller name="ctrlRewardsType" alias="奖池类型" pages="0,,1,,2," selected="1"/>
   <displayList>
-    <loader id="n0_l5nz" name="bg" xy="540,960" pivot="0.5,0.5" anchor="true" size="1080,2400" url="ui://drx9d1uso1391h" fill="scaleMatchWidth">
+    <loader id="n0_l5nz" name="bg" xy="540,960" pivot="0.5,0.5" anchor="true" size="1080,2400" url="ui://drx9d1uso1391i" fill="scaleMatchWidth">
       <gearIcon controller="ctrlRewardsType" pages="0,1,2" values="ui://drx9d1uso1391h|ui://drx9d1uso1391i|ui://drx9d1uso1391g"/>
       <relation target="" sidePair="center-center,middle-middle"/>
     </loader>
@@ -74,7 +74,7 @@
     <component id="n53_e050" name="comStar1_2_9" src="l5nzq" fileName="components/ComStar.xml" xy="626,867" group="n30_iakb"/>
     <group id="n30_iakb" name="grpComStar2" xy="196,223" size="688,1531" advanced="true">
       <gearDisplay controller="ctrlBuyType" pages="1"/>
-      <gearDisplay2 controller="ctrlRewardsType" pages="2" condition="0"/>
+      <gearDisplay2 controller="ctrlRewardsType" pages="2,6" condition="0"/>
       <relation target="" sidePair="center-center,top-top"/>
     </group>
     <movieclip id="n49_hibu" name="effEnd" src="hibu2m" fileName="effect/MovieClip3.jta" xy="0,0" size="1080,1920" visible="false">

+ 1 - 0
FGUIProject/assets/LuckyBox/components/ComStar.xml

@@ -3,5 +3,6 @@
   <controller name="c1" pages="0,,1," selected="0"/>
   <displayList>
     <component id="n8_t6j1" name="comLine" src="duufteb" fileName="components/ComponentLine.xml" xy="5,5" pivot="0,0.5" anchor="true" size="850,24"/>
+    <graph id="n9_jx6z" name="n9" xy="-41,-45" size="100,100" type="rect"/>
   </displayList>
 </component>

+ 1 - 1
GameClient/Assets/Game/HotUpdate/Data/LuckyBoxDataManager.cs

@@ -24,7 +24,7 @@ namespace GFGGame
 
 
         public int times = 0;
-        public int luckyBoxId;
+        public int luckyBoxIndex;
         public List<ItemData> RewardList
         {
             get { return _rewardsList; }

+ 1 - 1
GameClient/Assets/Game/HotUpdate/ServerProxy/LuckyBoxSProxy.cs

@@ -20,7 +20,7 @@ namespace GFGGame
                         ActivityDataManager.Instance.allPlayTimes += response.Times;
                     }
                     LuckyBoxDataManager.Instance.times = response.Times;
-                    LuckyBoxDataManager.Instance.luckyBoxId = response.LuckyBoxId;
+                    // LuckyBoxDataManager.Instance.luckyBoxIndex = response.LuckyBoxId;
                     LuckyBoxDataManager.Instance.RewardList = ItemUtil.CreateItemDataList(response.bonusList);
                     return true;
                 }

+ 1 - 0
GameClient/Assets/Game/HotUpdate/Views/LuckyBox/LuckyBoxActivityView.cs

@@ -73,6 +73,7 @@ namespace GFGGame
             _valueBarController.UpdateList(new List<int>() { _luckyBoxCfg.costID });
             _luckyBoxCtrl.OnShown(_luckyBoxCfg.id);
             LuckyBoxDataManager.Instance.currentBoxId = _luckyBoxCfg.id;
+            LuckyBoxDataManager.Instance.luckyBoxIndex = 2;
             UpGiftBox();
             Timers.inst.Add(1, 0, UpdateTime);
             UpdateView();

+ 0 - 2
GameClient/Assets/Game/HotUpdate/Views/LuckyBox/LuckyBoxNewDressView.cs

@@ -99,8 +99,6 @@ namespace GFGGame
                 }
             }
 
-            LuckyBoxDataManager.Instance.luckyBoxId = 0;
-
             UpdateView();
         }
         private void UpdateView()

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

@@ -122,7 +122,7 @@ namespace GFGGame
             _ui.m_ctrlBuyType.selectedIndex = _rewardList != null && _rewardList.Count > 1 ? 1 : 0;
 
             _isLuckyBox = LuckyBoxDataManager.Instance.luckyBoxIds.IndexOf(LuckyBoxDataManager.Instance.currentBoxId) >= 0;
-            _ui.m_ctrlRewardsType.selectedIndex = _isLuckyBox ? (LuckyBoxDataManager.Instance.currentBoxId - 1) : 0;
+            _ui.m_ctrlRewardsType.selectedIndex = LuckyBoxDataManager.Instance.luckyBoxIndex;// _isLuckyBox ? (LuckyBoxDataManager.Instance.currentBoxId - 1) : 0;
             // string resPath = string.Format("cj_tp_{0}", _isLuckyBox ? LuckyBoxDataManager.Instance.currentBoxId : 1);
             _ui.m_bg.url = ResPathUtil.GetBgImgPath("zx_bg");
 

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

@@ -125,6 +125,8 @@ namespace GFGGame
             _ui.m_listBg.numItems = LuckyBoxDataManager.Instance.luckyBoxIds.Count;
             _ui.m_listBg.ScrollToView(_curIndex);
             _ui.m_listBg.scrollPane.decelerationRate = 0.8f;
+            LuckyBoxDataManager.Instance.luckyBoxIndex = _curIndex;
+
 
             OnListBgScroll();
             updateBoxEffect();
@@ -190,7 +192,7 @@ namespace GFGGame
             UpdateListItem();
             _ui.m_btnLeft.grayed = _curIndex <= 0;
             _ui.m_btnRight.grayed = _curIndex >= _ui.m_listBg.numItems - 1;
-
+            LuckyBoxDataManager.Instance.luckyBoxIndex = _curIndex;
         }
 
         private void UpdateListItem()

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