瀏覽代碼

Merge remote-tracking branch 'remotes/origin/master' into xiaojie

hexiaojie 2 年之前
父節點
當前提交
248fd47fbe

+ 6 - 0
GameClient/Assets/Game/HotUpdate/Data/TaskDataManager.cs

@@ -102,6 +102,12 @@ namespace GFGGame
                 var stateA = TaskInfosDic[a.id].State == 1 ? 1 : -1;
                 var stateB = TaskInfosDic[b.id].State == 1 ? 1 : -1;
                 if (stateA > stateB) return -1;
+                else if (stateA == stateB) { 
+                    if(a.id > b.id) 
+                        return 1;
+                    else
+                        return -1;
+                }
                 return stateB > stateA ? 1 : TaskInfosDic[a.id].State.CompareTo(TaskInfosDic[b.id].State);
             });
             return cfgs;

+ 6 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/CreateRole/UI_CreateRoleUI.cs

@@ -10,6 +10,8 @@ namespace UI.CreateRole
         public GLoader m_loaBg;
         public UI_EnvelopeModel m_envelopeModel;
         public Transition m_t_Open;
+        public Transition m_t_In;
+        public Transition m_t_AfterOpen;
         public const string URL = "ui://5al8chbdxt5s0";
         public const string PACKAGE_NAME = "CreateRole";
         public const string RES_NAME = "CreateRoleUI";
@@ -60,6 +62,8 @@ namespace UI.CreateRole
             m_loaBg = (GLoader)comp.GetChild("loaBg");
             m_envelopeModel = (UI_EnvelopeModel)UI_EnvelopeModel.Create(comp.GetChild("envelopeModel"));
             m_t_Open = comp.GetTransition("t_Open");
+            m_t_In = comp.GetTransition("t_In");
+            m_t_AfterOpen = comp.GetTransition("t_AfterOpen");
         }
         public void Dispose(bool disposeTarget = false)
         {
@@ -67,6 +71,8 @@ namespace UI.CreateRole
             m_envelopeModel.Dispose();
             m_envelopeModel = null;
             m_t_Open = null;
+            m_t_In = null;
+            m_t_AfterOpen = null;
             if(disposeTarget && target != null)
             {
                 target.RemoveFromParent();

+ 8 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/PopWindow.meta

@@ -0,0 +1,8 @@
+fileFormatVersion: 2
+guid: cc53a06d9d56736418cf81667932a9e8
+folderAsset: yes
+DefaultImporter:
+  externalObjects: {}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 74 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/PopWindow/UI_ExchangeGoodsUI.cs

@@ -0,0 +1,74 @@
+/** This is an automatically generated class by FairyGUI. Please do not modify it. **/
+
+using FairyGUI;
+
+namespace UI.PopWindow
+{
+    public partial class UI_ExchangeGoodsUI
+    {
+        public GComponent target;
+        public GGraph m_holderLeftTop;
+        public GGraph m_holderRightDowm;
+        public const string URL = "ui://i9tn319dnzuq0";
+        public const string PACKAGE_NAME = "PopWindow";
+        public const string RES_NAME = "ExchangeGoodsUI";
+        private static UI_ExchangeGoodsUI _proxy;
+
+        public static UI_ExchangeGoodsUI Create(GObject gObject = null)
+        {
+            var ui = new UI_ExchangeGoodsUI();
+            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_ExchangeGoodsUI Proxy(GObject gObject = null)
+        {
+            if(_proxy == null)
+            {
+                _proxy = new UI_ExchangeGoodsUI();
+            }
+            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_holderLeftTop = (GGraph)comp.GetChild("holderLeftTop");
+            m_holderRightDowm = (GGraph)comp.GetChild("holderRightDowm");
+        }
+        public void Dispose(bool disposeTarget = false)
+        {
+            m_holderLeftTop = null;
+            m_holderRightDowm = null;
+            if(disposeTarget && target != null)
+            {
+                target.RemoveFromParent();
+                target.Dispose();
+            }
+            target = null;
+        }
+    }
+}

+ 11 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/PopWindow/UI_ExchangeGoodsUI.cs.meta

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

+ 6 - 0
GameClient/Assets/Game/HotUpdate/FairyGUI/GenCode/Studio/UI_ListLevelItem.cs

@@ -16,6 +16,8 @@ namespace UI.Studio
         public GImage m_imgLockBg;
         public GImage m_imgLock;
         public GGroup m_grpLock;
+        public Transition m_ToLeft;
+        public Transition m_ToRight;
         public const string URL = "ui://xz8kxrecv4822p";
         public const string PACKAGE_NAME = "Studio";
         public const string RES_NAME = "ListLevelItem";
@@ -72,6 +74,8 @@ namespace UI.Studio
             m_imgLockBg = (GImage)comp.GetChild("imgLockBg");
             m_imgLock = (GImage)comp.GetChild("imgLock");
             m_grpLock = (GGroup)comp.GetChild("grpLock");
+            m_ToLeft = comp.GetTransition("ToLeft");
+            m_ToRight = comp.GetTransition("ToRight");
         }
         public void Dispose(bool disposeTarget = false)
         {
@@ -85,6 +89,8 @@ namespace UI.Studio
             m_imgLockBg = null;
             m_imgLock = null;
             m_grpLock = null;
+            m_ToLeft = null;
+            m_ToRight = null;
             if(disposeTarget && target != null)
             {
                 target.RemoveFromParent();

+ 1 - 1
GameClient/Assets/Game/HotUpdate/Views/CreateRole/CreateRoleView.cs

@@ -67,7 +67,7 @@ namespace GFGGame
                     _effectUIDic.Add("FX_LiuSu", EffectUIPool.CreateEffectUI(_ui.m_envelopeModel.m_envelope.m_LiuSuEffectHolder, "ui_CreateRoleUI/Before_Open", "FX_LiuSu"));
                     _effectUIDic.Add("FX_taril", EffectUIPool.CreateEffectUI(_ui.m_envelopeModel.m_trailEffectHolder, "ui_CreateRoleUI/Before_Open", "FX_taril"));
 
-                    _ui.m_envelopeModel.m_t_In.Play(() =>
+                    _ui.m_t_In.Play(() =>
                     {
                         ChangeAnimationState(State.IDLE);
                     });

+ 8 - 0
GameClient/Assets/Game/HotUpdate/Views/PopWindow.meta

@@ -0,0 +1,8 @@
+fileFormatVersion: 2
+guid: 4e3f8e73d15545241b218aeb9d327d3e
+folderAsset: yes
+DefaultImporter:
+  externalObjects: {}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 65 - 0
GameClient/Assets/Game/HotUpdate/Views/PopWindow/ExchangeGoodsView.cs

@@ -0,0 +1,65 @@
+using FairyGUI;
+using UI.PopWindow;
+
+namespace GFGGame
+{
+    public class ExchangeGoodsView : BaseWindow
+    {
+        private UI_ExchangeGoodsUI _ui;
+
+        public override void Dispose()
+        {
+            if (_ui != null)
+            {
+                _ui.Dispose();
+                _ui = null;
+            }
+
+            base.Dispose();
+        }
+
+        protected override void OnInit()
+        {
+            base.OnInit();
+            packageName = UI_ExchangeGoodsUI.PACKAGE_NAME;
+            _ui = UI_ExchangeGoodsUI.Create();
+            viewCom = _ui.target;
+            isfullScreen = true;
+            bringToFontOnClick = false;
+            //_ui.m_btnBack.onClick.Add(OnBtnBackClick);
+        }
+
+        private void OnBtnBackClick()
+        {
+            ViewManager.Hide<CombTaskController>();
+            //ViewManager.Hide<BattlePassTaskView>();
+            ViewManager.GoBackFrom(typeof(TaskView).FullName);
+        }
+
+        private void OnBtnAchieveClick()
+        {
+            ViewManager.Show<TaskAchieveView>();
+        }
+            
+        protected override void AddEventListener()
+        {
+            base.AddEventListener();
+        }
+
+        protected override void RemoveEventListener()
+        {
+            base.RemoveEventListener();
+        }
+
+        protected override void OnShown()
+        {
+            base.OnShown();
+          
+        }
+
+        protected override void OnHide()
+        {
+            base.OnHide();
+        }
+    }
+}

+ 11 - 0
GameClient/Assets/Game/HotUpdate/Views/PopWindow/ExchangeGoodsView.cs.meta

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

+ 30 - 0
GameClient/Assets/Game/HotUpdate/Views/Studio/StudioFilingView.cs

@@ -13,6 +13,7 @@ namespace GFGGame
         private StudioCfg _studioCfg;
         private List<StoryLevelCfg> _storyLevelCfgs;
         private int _viewData = 0;
+        private int itemIndex = 0;
 
         public override void Dispose()
         {
@@ -68,6 +69,8 @@ namespace GFGGame
 
             UpdateView();
             Timers.inst.AddUpdate(CheckGuide);
+
+            UpdateItem();
         }
 
         protected override void OnHide()
@@ -75,6 +78,7 @@ namespace GFGGame
             base.OnHide();
             _valueBarController.OnHide();
             Timers.inst.Remove(CheckGuide);
+            Timers.inst.Remove(AddItemUpdate);
 
         }
         protected void GoBackFrom()
@@ -253,5 +257,31 @@ namespace GFGGame
             GuideController.TryCompleteGuide(ConstGuideId.STUDIO_FILING, 5);
 
         }
+
+        private void UpdateItem()
+        {
+            for (int i = 0; i < _ui.m_list.numChildren; i++)
+            {
+                _ui.m_list.GetChildAt(i).visible = false;
+            }
+            itemIndex = 0;
+            Timers.inst.Add(0.2f, _ui.m_list.numChildren, AddItemUpdate, 1);
+        }
+
+        private void AddItemUpdate(object param)
+        {
+            _ui.m_list.GetChildAt(itemIndex).visible = true;
+            UI_ListLevelItem item = UI_ListLevelItem.Proxy(_ui.m_list.GetChildAt(itemIndex));
+            if (itemIndex % 2 == 0)
+            {
+                item.m_ToLeft.Play();
+            }
+            else
+            {
+                item.m_ToRight.Play();
+            }
+            itemIndex++;
+            UI_ListLevelItem.ProxyEnd();
+        }
     }
 }

+ 4 - 4
GameClient/Assets/Game/HotUpdate/Views/Task/TaskAchieveDetailView.cs

@@ -39,7 +39,6 @@ namespace GFGGame
         {
             ViewManager.Hide<TaskAchieveDetailView>();
         }
-
     
         protected override void AddEventListener()
         {
@@ -55,6 +54,7 @@ namespace GFGGame
         {
             base.OnShown();
             UpdateTask();
+            _ui.m_listAchieveTask.ScrollToView(0);
         }
 
         protected override void OnHide()
@@ -68,9 +68,9 @@ namespace GFGGame
             _ui.m_AchieveType.selectedIndex = taskSubType;
             _cfgsAll = TaskDataManager.Instance.GetTaskCfgs(funcType);
             _cfgs.Clear();
-            foreach (var info in _cfgsAll) {
-                if (info.achievementType == taskSubType+1)
-                    _cfgs.Add(info);
+            for (int i= 0; i< _cfgsAll.Count;i++) {
+                if (_cfgsAll[i].achievementType == taskSubType+1)
+                    _cfgs.Add(_cfgsAll[i]);
             }
             _ui.m_listAchieveTask.numItems = _cfgs.Count;
         }

+ 1 - 1
GameClient/Assets/Game/HotUpdate/Views/Task/TaskAchieveView.cs

@@ -103,7 +103,7 @@ namespace GFGGame
                 }
             }
 
-            RedDotController.Instance.SetComRedDot(listItem.target, TaskDataManager.Instance.CheckTaskSubRewardCanGet(TaskFuncType.Achievement, index),"",-10,60);
+            RedDotController.Instance.SetComRedDot(listItem.target, TaskDataManager.Instance.CheckTaskSubRewardCanGet(TaskFuncType.Achievement, index),"",-30,120);
 
             UI_AchieveItem.ProxyEnd();
         }

二進制
GameClient/Assets/ResIn/UI/CommonGame/CommonGame_fui.bytes


二進制
GameClient/Assets/ResIn/UI/CreateRole/CreateRole_fui.bytes


二進制
GameClient/Assets/ResIn/UI/Studio/Studio_fui.bytes