| 
					
				 | 
			
			
				@@ -15,6 +15,17 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         private UI_SpecialOfferGiftBoxUI _ui; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         private int _pageIndex; //当前页码,需要显示的数据的索引 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        private List<GGraph> _graphList = new List<GGraph>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        private List<GameObject> _gameObjectList = new List<GameObject>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        private List<GoWrapper> _wrapperList = new List<GoWrapper>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        private GameObject _gameObject1; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        private GameObject _gameObject2; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        private GameObject _gameObject3; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        private GoWrapper _wrapper1; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        private GoWrapper _wrapper2; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        private GoWrapper _wrapper3; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         protected override void OnInit() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         { 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -46,6 +57,7 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         protected override void OnShown() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             base.OnShown(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            _ui.m_t0.Play(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             AddEffect(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             InitPageInex(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -70,6 +82,15 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         private void AddEffect() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            string resPath1 = ResPathUtil.GetViewEffectPath("ui_Activity", "Prefer_person"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            SceneController.AddObjectToView(null, null, _ui.m_holderBaby, resPath1, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                out _gameObject1, out _wrapper1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            string resPath2 = ResPathUtil.GetViewEffectPath("ui_Activity", "Prefer_chixu_tx"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            SceneController.AddObjectToView(null, null, _ui.m_holderChiXuTx, resPath2, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                out _gameObject2, out _wrapper2); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            string resPath3 = ResPathUtil.GetViewEffectPath("ui_Activity", "Prefer_one_tx"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            SceneController.AddObjectToView(null, null, _ui.m_holderOneTx, resPath3, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                out _gameObject3, out _wrapper3); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         public void UpTime() 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -109,7 +130,7 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             var data = ListUtil.Navigate(list, type, _pageIndex, out int newIndex); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             _pageIndex = newIndex; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-             
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             _ui.m_btnUp.visible = true; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             _ui.m_btnNext.visible = true; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             if (list.Count == 1) 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -199,7 +220,7 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 uiItem.m_btnBuy.m_txtNewPrice.align = AlignType.Left; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 uiItem.m_btnBuy.m_txtNewPrice.x = 125; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 uiItem.m_btnBuy.m_txtOldPrice.x = 30; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                uiItem.m_txtGetJf.text = $"可获得{shopCfg.price * 10}充值经验"; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                uiItem.m_txtGetJf.text = $"可获得{shopCfg.price * 10}会员积分"; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             else 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             { 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -216,7 +237,29 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             uiItem.m_txtUrc.text = mTxtUrc; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             uiItem.m_btnBuy.target.onClick.Add(OnBtnBuyClick); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             uiItem.m_txtBoxItemName.text = shopCfg.itemName; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-             
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (!_graphList.Contains(uiItem.m_holderZheKou)) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                string resPath = ResPathUtil.GetViewEffectPath("ui_Activity", "Prefer_but_zhekou"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                SceneController.AddObjectToView(null, null, uiItem.m_holderZheKou, resPath, out var gameObject, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    out var wrapper); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                _graphList.Add(uiItem.m_holderZheKou); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                _gameObjectList.Add(gameObject); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                _wrapperList.Add(wrapper); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (!_graphList.Contains(uiItem.m_holderBtn)) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                string resPath = ResPathUtil.GetViewEffectPath("ui_Activity", "Prefer_button_buy"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                SceneController.AddObjectToView(null, null, uiItem.m_holderBtn, resPath, out var gameObject, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    out var wrapper); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                _graphList.Add(uiItem.m_holderBtn); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                _gameObjectList.Add(gameObject); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                _wrapperList.Add(wrapper); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            uiItem.m_t0.Play(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             //子列表 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             uiItem.m_list.itemRenderer = ChildListItemRender; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             uiItem.m_list.numItems = shopItemCfg.itemsArr.Length; 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -254,6 +297,17 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             uiItemChild.m_loaIcon.url = ResPathUtil.GetIconPath(itemCfgChild); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             uiItemChild.m_num.text = itemArr[1].ToString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             uiItemChild.target.data = itemCfgChild; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (!_graphList.Contains(uiItemChild.m_holderItem)) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                string resPath = ResPathUtil.GetViewEffectPath("ui_Activity", "Prefer_kuang"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                SceneController.AddObjectToView(null, null, uiItemChild.m_holderItem, resPath, out var gameObject, 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    out var wrapper); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                _graphList.Add(uiItemChild.m_holderItem); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                _gameObjectList.Add(gameObject); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                _wrapperList.Add(wrapper); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             UI_ComRewardIconItem.ProxyEnd(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -314,9 +368,38 @@ namespace GFGGame 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 ViewManager.Show<ItemExchangeView>(cfg.id); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+         
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        private void DestroyObjectFromView() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            foreach (var itemGameObject in _gameObjectList) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                if (itemGameObject != null) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    GameObject.DestroyImmediate(itemGameObject); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+             
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            _gameObjectList.Clear(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            foreach (var itemWrapper in _wrapperList) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                if (itemWrapper != null) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    itemWrapper.Dispose(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            _wrapperList.Clear(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            _graphList.Clear(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         protected override void OnHide() 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+             
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            SceneController.DestroyObjectFromView(_gameObject1, _wrapper1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            SceneController.DestroyObjectFromView(_gameObject2, _wrapper2); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            SceneController.DestroyObjectFromView(_gameObject3, _wrapper3); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            DestroyObjectFromView(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             this.RemoveEventListener(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             Dispose(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             base.Hide(); 
			 |