From 862ef8b6cc1ccc7993d3dcd5c1cf0799ec12a752 Mon Sep 17 00:00:00 2001
From: client_Wu Xijin <364452445@qq.com>
Date: 星期一, 25 二月 2019 18:06:10 +0800
Subject: [PATCH] 6255 【前端】【2.0】神秘商店开发
---
System/Store/StoreWin.cs | 449 ++++++++++++++++++++++++++-----------------------------
1 files changed, 213 insertions(+), 236 deletions(-)
diff --git a/System/Store/StoreWin.cs b/System/Store/StoreWin.cs
index 6af01ae..c0dc13a 100644
--- a/System/Store/StoreWin.cs
+++ b/System/Store/StoreWin.cs
@@ -11,62 +11,35 @@
using Snxxz.UI;
-namespace Snxxz.UI {
-
+namespace Snxxz.UI
+{
public class StoreWin : Window
{
- #region 鎴愬憳鍙橀噺
- [SerializeField]
- private FunctionButton _weekStoreTitle;
- [SerializeField]
- private FunctionButton _commonStoreTitle;
- [SerializeField]
- private FunctionButton _growStrongerStoreTitle;
- [SerializeField]
- private FunctionButton _bindStoreTitle;
- [SerializeField]
- private FunctionButton _integralStoreTitle;
- [SerializeField]
- private FunctionButtonGroup _funcBtnGroup;
+ [SerializeField] FunctionButton m_WeekStoreTitle;
+ [SerializeField] FunctionButton m_CommonStoreTitle;
+ [SerializeField] FunctionButton m_GrowStrongerStoreTitle;
+ [SerializeField] FunctionButton m_BindStoreTitle;
+ [SerializeField] FunctionButton m_IntegralStoreTitle;
+ [SerializeField] FunctionButtonGroup m_FuncBtnGroup;
+ [SerializeField] Button m_LeftBtn;
+ [SerializeField] Button m_RightBtn;
+ [SerializeField] Button m_CloseBtn;
+ [SerializeField] ScrollerController m_ShopCtrl;
+ [SerializeField] GameObject m_FollowStoreBottom;
+ [SerializeField] Text m_CoinsType1;
+ [SerializeField] Text m_CoinsType2;
+ [SerializeField] Text m_CoinsType3;
+ [SerializeField] RectTransform m_RefreshContainer;
+ [SerializeField] Button m_RefreshCommodities;
+ [SerializeField] Text m_RefreshTimeText;
+ [SerializeField] GameObject m_IntegralBottom;
+ [SerializeField] Button m_AssistBtn;
- [SerializeField]
- private Button _leftBtn;
+ StoreModel model { get { return ModelCenter.Instance.GetModel<StoreModel>(); } }
- [SerializeField]
- private Button _rightBtn;
-
- [SerializeField]
- private Button _closeBtn;
-
- [SerializeField]
- private ScrollerController _shopCtrl;
-
- [SerializeField]
- private GameObject _followStoreBottom;
- [SerializeField]
- private Text _coinsType1;
- [SerializeField]
- private Text _coinsType2;
- [SerializeField]
- private Text _resetRefreshTimeText;
-
- [SerializeField]
- private GameObject _integralBottom;
- [SerializeField]
- private Text _coinsType3;
- [SerializeField] Button assistBtn;
- #endregion
-
- StoreModel _storeModel;
- StoreModel m_storeModel
- {
- get { return _storeModel ?? (_storeModel = ModelCenter.Instance.GetModel<StoreModel>()); }
- }
-
- private List<StoreModel.StoreData> _tagStoreModellist;
- private FuncConfigConfig _tagFuncModel1;
- private FuncConfigConfig _tagFuncModel2;
+ private List<StoreModel.StoreData> commodities;
private int shopId = 0;
+
#region Built-in
protected override void BindController()
{
@@ -74,63 +47,65 @@
protected override void AddListeners()
{
- _shopCtrl.OnRefreshCell += RefreshShopCell;
- _shopCtrl.lockType = EnhanceLockType.KeepVertical;
+ m_ShopCtrl.OnRefreshCell += RefreshShopCell;
+ m_ShopCtrl.lockType = EnhanceLockType.KeepVertical;
- _weekStoreTitle.onClick.AddListener(()=> { OnClickWeekStore(); });
- _commonStoreTitle.onClick.AddListener(()=> { OnClickCommonStore();});
- _growStrongerStoreTitle.onClick.AddListener(()=>{ OnClickStrengthStore();});
- _bindStoreTitle.onClick.AddListener(()=> { OnClickBindStore(); });
- _integralStoreTitle.onClick.AddListener(()=> { OnClickIntegralStore(); });
- _leftBtn.onClick.AddListener(OnClickLeftBtn);
- _rightBtn.onClick.AddListener(OnClickRightBtn);
- _closeBtn.onClick.AddListener(OnClickClose);
- assistBtn.AddListener(ClickAssistBtn);
+ m_WeekStoreTitle.SetListener(OpenMysteryStore);
+ m_CommonStoreTitle.SetListener(OpenCommonStore);
+ m_GrowStrongerStoreTitle.SetListener(OpenStrengthStore);
+ m_BindStoreTitle.SetListener(OpenBindGoldStore);
+ m_IntegralStoreTitle.SetListener(OpenIntegralStore);
+ m_AssistBtn.SetListener(ViewAssistRecorders);
+ m_RefreshCommodities.SetListener(RefreshCommondities);
+ m_LeftBtn.SetListener(() => { m_FuncBtnGroup.TriggerLast(); });
+ m_RightBtn.SetListener(() => { m_FuncBtnGroup.TriggerNext(); });
+ m_CloseBtn.SetListener(() => { CloseImmediately(); });
}
protected override void OnPreOpen()
{
shopId = 0;
- m_storeModel.RefreshTCBPlayerDataEvent += OnRefreshPlayerInfo;
- m_storeModel.RefreshBuyShopLimitEvent += OnCreate;
+ model.RefreshTCBPlayerDataEvent += OnRefreshPlayerInfo;
+ model.RefreshBuyShopLimitEvent += OnCreate;
+ GlobalTimeEvent.Instance.secondEvent += UpdateRefreshTime;
RefreshCoins();
- RefreshResetTime();
- m_storeModel.SetPushPetAndMountWinState(true,true);
+ UpdateRefreshTime();
+ model.SetPushPetAndMountWinState(true, true);
}
protected override void OnActived()
{
base.OnActived();
- if(!WindowJumpMgr.Instance.IsJumpState && functionOrder == 0)
+ if (!WindowJumpMgr.Instance.IsJumpState && functionOrder == 0)
{
- if(m_storeModel.storeFunc1Point.state == RedPointState.Simple)
+ if (model.storeFunc1Point.state == RedPointState.Simple)
{
- functionOrder = _weekStoreTitle.order;
+ functionOrder = m_WeekStoreTitle.order;
}
- else if(m_storeModel.storeFunc2Point.state == RedPointState.Simple)
+ else if (model.storeFunc2Point.state == RedPointState.Simple)
{
- functionOrder = _commonStoreTitle.order;
+ functionOrder = m_CommonStoreTitle.order;
}
- else if (m_storeModel.storeFunc3Point.state == RedPointState.Simple)
+ else if (model.storeFunc3Point.state == RedPointState.Simple)
{
- functionOrder = _growStrongerStoreTitle.order;
+ functionOrder = m_GrowStrongerStoreTitle.order;
}
- else if (m_storeModel.storeFunc4Point.state == RedPointState.Simple)
+ else if (model.storeFunc4Point.state == RedPointState.Simple)
{
- functionOrder = _bindStoreTitle.order;
+ functionOrder = m_BindStoreTitle.order;
}
- else if (m_storeModel.storeFunc5Point.state == RedPointState.Simple)
+ else if (model.storeFunc5Point.state == RedPointState.Simple)
{
- functionOrder = _integralStoreTitle.order;
+ functionOrder = m_IntegralStoreTitle.order;
}
}
- if(!WindowJumpMgr.Instance.IsJumpState && m_storeModel.funcOrder != -1)
+ if (!WindowJumpMgr.Instance.IsJumpState && model.funcOrder != -1)
{
- functionOrder = m_storeModel.funcOrder;
+ functionOrder = model.funcOrder;
}
- _funcBtnGroup.TriggerByOrder(functionOrder);
- GlobalTimeEvent.Instance.secondEvent += RefreshResetTime;
+
+ m_FuncBtnGroup.TriggerByOrder(functionOrder);
}
protected override void OnAfterOpen()
@@ -140,12 +115,11 @@
protected override void OnPreClose()
{
- m_storeModel.CloseAllRedpoint(StoreFunc.WeekStore);
- m_storeModel.storeFuncType = StoreFunc.WeekStore;
- m_storeModel.RefreshBuyShopLimitEvent -= OnCreate;
- GlobalTimeEvent.Instance.secondEvent -= RefreshResetTime;
- m_storeModel.RefreshTCBPlayerDataEvent -= OnRefreshPlayerInfo;
-
+ model.CloseAllRedpoint(StoreFunc.MysteryStore);
+ model.storeFuncType = StoreFunc.MysteryStore;
+ model.RefreshBuyShopLimitEvent -= OnCreate;
+ GlobalTimeEvent.Instance.secondEvent -= UpdateRefreshTime;
+ model.RefreshTCBPlayerDataEvent -= OnRefreshPlayerInfo;
}
protected override void OnAfterClose()
@@ -161,21 +135,21 @@
{
if (AchievementGoto.guideAchievementId != 0)
{
- SuccessConfig successConfig = SuccessConfig.Get(AchievementGoto.guideAchievementId);
- if(successConfig.Type == 97)
+ var successConfig = SuccessConfig.Get(AchievementGoto.guideAchievementId);
+ if (successConfig.Type == 97)
{
- _tagStoreModellist = m_storeModel.TryGetStoreDatas((int)m_storeModel.storeFuncType);
+ commodities = model.TryGetStoreDatas(model.storeFuncType);
List<StoreModel.StoreData> orderlist = new List<StoreModel.StoreData>();
- orderlist.AddRange(_tagStoreModellist);
+ orderlist.AddRange(commodities);
orderlist.Sort(CompareByMoney);
- for (int i = 0; i < _tagStoreModellist.Count; i++)
+ for (int i = 0; i < commodities.Count; i++)
{
- if (_tagStoreModellist[i].shopId == orderlist[0].shopId)
+ if (commodities[i].shopId == orderlist[0].shopId)
{
- shopId = _tagStoreModellist[i].shopId;
+ shopId = commodities[i].shopId;
int index = i / 2;
- _shopCtrl.JumpIndex(index);
- _shopCtrl.m_Scorller.RefreshActiveCellViews();
+ m_ShopCtrl.JumpIndex(index);
+ m_ShopCtrl.m_Scorller.RefreshActiveCellViews();
break;
}
}
@@ -184,144 +158,159 @@
}
else
{
- if(m_storeModel.jumpShopId != 0)
+ if (model.jumpShopId != 0)
{
- _tagStoreModellist = m_storeModel.TryGetStoreDatas((int)m_storeModel.storeFuncType);
- for (int i = 0; i < _tagStoreModellist.Count; i++)
+ commodities = model.TryGetStoreDatas(model.storeFuncType);
+ for (int i = 0; i < commodities.Count; i++)
{
- if (_tagStoreModellist[i].shopId == m_storeModel.jumpShopId)
+ if (commodities[i].shopId == model.jumpShopId)
{
- shopId = _tagStoreModellist[i].shopId;
- int index = i / 2 ;
- _shopCtrl.JumpIndex(index > 2 ? index - 1 : index);
- _shopCtrl.m_Scorller.RefreshActiveCellViews();
+ shopId = commodities[i].shopId;
+ int index = i / 2;
+ m_ShopCtrl.JumpIndex(index > 2 ? index - 1 : index);
+ m_ShopCtrl.m_Scorller.RefreshActiveCellViews();
break;
}
}
- m_storeModel.ClearJumpModel();
+ model.ClearJumpModel();
}
}
}
- private void RefreshResetTime()
+ private void UpdateRefreshTime()
{
- if(_tagStoreModellist == null || _tagStoreModellist.Count < 1)
+ if (commodities == null || commodities.Count < 1)
{
- _tagStoreModellist = m_storeModel.TryGetStoreDatas((int)m_storeModel.storeFuncType);
+ commodities = model.TryGetStoreDatas(model.storeFuncType);
}
- if(_tagStoreModellist.Count > 0)
+ if (commodities == null || commodities.Count == 0)
{
- if (_tagStoreModellist[0].storeConfig.RefreshType == 0)
- {
- _resetRefreshTimeText.gameObject.SetActive(false);
- }
- else
- {
- _resetRefreshTimeText.gameObject.SetActive(true);
- _resetRefreshTimeText.text = m_storeModel.GetStoreRefreshTimeByType(_tagStoreModellist[0].storeConfig.RefreshType);
- }
+ return;
}
+
+ var refreshType = commodities[0].storeConfig.RefreshType;
+ if (refreshType == 0)
+ {
+ m_RefreshContainer.gameObject.SetActive(false);
+ }
+ else
+ {
+ m_RefreshCommodities.gameObject.SetActive(model.storeFuncType == StoreFunc.MysteryStore);
+ m_RefreshContainer.gameObject.SetActive(true);
+ m_RefreshTimeText.text = model.GetStoreRefreshTimeByType(refreshType);
+ }
+
}
-
- public int CompareByMoney(StoreModel.StoreData start, StoreModel.StoreData end)
+ int CompareByMoney(StoreModel.StoreData start, StoreModel.StoreData end)
{
int money1 = start.storeConfig.MoneyNumber;
int money2 = end.storeConfig.MoneyNumber;
- if (money1.CompareTo(money2) != 0) return money1.CompareTo(money2);
- int index1 = _tagStoreModellist.IndexOf(start);
- int index2 = _tagStoreModellist.IndexOf(end);
- if (index1.CompareTo(index2) != 0) return index1.CompareTo(index2);
+ if (money1 != money2)
+ {
+ return money1.CompareTo(money2);
+ }
+
+ int index1 = commodities.IndexOf(start);
+ int index2 = commodities.IndexOf(end);
+ if (index1 != index2)
+ {
+ return index1.CompareTo(index2);
+ }
return 0;
}
private void RefreshUI()
{
- if (_tagStoreModellist.Count < 1)
- return;
-
- if(m_storeModel.showCoinsUIDict != null && m_storeModel.showCoinsUIDict.ContainsKey(_tagStoreModellist[0].storeConfig.ShopType))
+ if (commodities.Count < 1)
{
- if(m_storeModel.showCoinsUIDict[_tagStoreModellist[0].storeConfig.ShopType] == 1)
- {
- _followStoreBottom.gameObject.SetActive(true);
- _integralBottom.gameObject.SetActive(false);
- }
- else if(m_storeModel.showCoinsUIDict[_tagStoreModellist[0].storeConfig.ShopType] == 2)
- {
- _followStoreBottom.gameObject.SetActive(false);
- _integralBottom.gameObject.SetActive(true);
- }
+ return;
}
+ var shopType = commodities[0].storeConfig.ShopType;
+ if (model.showCoinsUIDict != null && model.showCoinsUIDict.ContainsKey(shopType))
+ {
+ if (model.showCoinsUIDict[shopType] == 1)
+ {
+ m_FollowStoreBottom.gameObject.SetActive(true);
+ m_IntegralBottom.gameObject.SetActive(false);
+ }
+ else if (model.showCoinsUIDict[shopType] == 2)
+ {
+ m_FollowStoreBottom.gameObject.SetActive(false);
+ m_IntegralBottom.gameObject.SetActive(true);
+ }
+ }
}
public void RefreshCoins()
{
- _coinsType1.text = UIHelper.GetMoneyCnt(1).ToString();
- _coinsType2.text = UIHelper.GetMoneyCnt(2).ToString();
- _coinsType3.text = UIHelper.ReplaceXianYuanCoinsNum(UIHelper.GetMoneyCnt(17));
+ m_CoinsType1.text = UIHelper.GetMoneyCnt(1).ToString();
+ m_CoinsType2.text = UIHelper.GetMoneyCnt(2).ToString();
+ m_CoinsType3.text = UIHelper.ReplaceXianYuanCoinsNum(UIHelper.GetMoneyCnt(17));
}
private void OnCreate()
{
shopId = 0;
- _tagStoreModellist = m_storeModel.TryGetStoreDatas((int)m_storeModel.storeFuncType);
- _shopCtrl.Refresh();
- if (_tagStoreModellist.Count > 0)
+ commodities = model.TryGetStoreDatas(model.storeFuncType);
+ m_ShopCtrl.Refresh();
+ if (commodities.Count > 0)
{
- int i = 0;
- int remain = _tagStoreModellist.Count % 2;
- int line = (int)_tagStoreModellist.Count / 2;
+ int remain = commodities.Count % 2;
+ int line = (int)commodities.Count / 2;
if (remain > 0)
{
line += 1;
}
- for (i = 0; i < line; i++)
+ for (var i = 0; i < line; i++)
{
- _shopCtrl.AddCell(ScrollerDataType.Header, i);
+ m_ShopCtrl.AddCell(ScrollerDataType.Header, i);
}
}
- _shopCtrl.Restart();
- _shopCtrl.JumpIndex(0);
+ m_ShopCtrl.Restart();
+ m_ShopCtrl.JumpIndex(0);
RefreshUI();
}
private void OnRefreshPlayerInfo(PlayerDataRefresh refreshType)
{
- if (refreshType == PlayerDataRefresh.VIPLv)
- OnCreate();
- else if (refreshType == PlayerDataRefresh.Gold)
- RefreshCoins();
- else if (refreshType == PlayerDataRefresh.GoldPaper)
- RefreshCoins();
- else if(refreshType == PlayerDataRefresh.FBHelpPoint)
- RefreshCoins();
-
+ switch (refreshType)
+ {
+ case PlayerDataRefresh.VIPLv:
+ OnCreate();
+ break;
+ case PlayerDataRefresh.Gold:
+ case PlayerDataRefresh.GoldPaper:
+ case PlayerDataRefresh.FBHelpPoint:
+ RefreshCoins();
+ break;
+ default:
+ break;
+ }
}
private void RefreshShopCell(ScrollerDataType type, CellView cell)
{
- int childCode = 0;
- for (childCode = 0; childCode < cell.transform.childCount; childCode++)
+ for (var i = 0; i < cell.transform.childCount; i++)
{
- int cellCount = (cell.transform.childCount) * cell.index + (childCode + 1);
- ShopItemCell shopItemCell = cell.transform.GetChild(childCode).GetComponent<ShopItemCell>();
- if(shopItemCell == null)
+ var cellCount = (cell.transform.childCount) * cell.index + (i + 1);
+ var shopItemCell = cell.transform.GetChild(i).GetComponent<ShopItemCell>();
+ if (shopItemCell == null)
{
- shopItemCell = cell.transform.GetChild(childCode).gameObject.AddComponent<ShopItemCell>();
+ shopItemCell = cell.transform.GetChild(i).gameObject.AddComponent<ShopItemCell>();
}
- if (_tagStoreModellist.Count >= cellCount)
+ if (commodities.Count >= cellCount)
{
- StoreConfig shopInfo = _tagStoreModellist[cellCount - 1].storeConfig;
- if(m_storeModel.shopRedDict.ContainsKey(shopInfo.ID))
+ StoreConfig shopInfo = commodities[cellCount - 1].storeConfig;
+ if (model.shopRedDict.ContainsKey(shopInfo.ID))
{
- shopItemCell.redpoint.redpointId = m_storeModel.shopRedDict[shopInfo.ID].id;
+ shopItemCell.redpoint.redpointId = model.shopRedDict[shopInfo.ID].id;
}
- cell.transform.GetChild(childCode).gameObject.SetActive(true);
+ cell.transform.GetChild(i).gameObject.SetActive(true);
if (shopInfo.SalesStatus.Trim() != "")
{
shopItemCell.stateImage.gameObject.SetActive(true);
@@ -333,12 +322,12 @@
shopItemCell.stateImage.gameObject.SetActive(false);
}
- ItemConfig chinModel = ItemConfig.Get(m_storeModel.GetReplaceId(shopInfo.ID,shopInfo.ItemID));
- if(chinModel != null)
+ var config = ItemConfig.Get(model.GetReplaceId(shopInfo.ID, shopInfo.ItemID));
+ if (config != null)
{
- ItemCellModel cellModel = new ItemCellModel(chinModel.ID,true,0,shopInfo.IsBind,"",PackType.Deleted,true);
+ ItemCellModel cellModel = new ItemCellModel(config.ID, true, 0, shopInfo.IsBind, "", PackType.Deleted, true);
shopItemCell.itemCell.Init(cellModel);
- shopItemCell.itemNameText.text = chinModel.ItemName;
+ shopItemCell.itemNameText.text = config.ItemName;
shopItemCell.coinsIcon.SetIconWithMoneyType(shopInfo.MoneyType);
ulong shopCost = (ulong)(shopInfo.MoneyNumber);
shopItemCell.coinNumText.text = UIHelper.ReplaceLargeNum(shopCost);
@@ -348,18 +337,18 @@
bool isVipBuy = buyItem.CheckIsVipBuy(shopInfo, out curVipIndex, out nextVipIndex);
int canBuyCnt = 0;
int addBuyCnt = 0;
- bool isLimitBuy = buyItem.CheckIsLimitBuyCnt(shopInfo,out canBuyCnt,out addBuyCnt);
+ bool isLimitBuy = buyItem.CheckIsLimitBuyCnt(shopInfo, out canBuyCnt, out addBuyCnt);
bool isShowBuyPrice = true;
- if(isVipBuy)
+ if (isVipBuy)
{
- if(curVipIndex == -1 && nextVipIndex != -1)
+ if (curVipIndex == -1 && nextVipIndex != -1)
{
shopItemCell.coinsIcon.gameObject.SetActive(false);
shopItemCell.vipText.gameObject.SetActive(true);
shopItemCell.vipText.text = Language.Get("StoreWin101", shopInfo.VIPLV[nextVipIndex]);
shopItemCell.sellImage.gameObject.SetActive(false);
- shopItemCell.itemNameText.color = UIHelper.GetUIColor(TextColType.Red,true);
- shopItemCell.vipText.color = UIHelper.GetUIColor(TextColType.Red,true);
+ shopItemCell.itemNameText.color = UIHelper.GetUIColor(TextColType.Red, true);
+ shopItemCell.vipText.color = UIHelper.GetUIColor(TextColType.Red, true);
isShowBuyPrice = false;
}
}
@@ -374,7 +363,7 @@
if (canBuyCnt > 0)
{
shopItemCell.itemCell.countText.gameObject.SetActive(true);
- BuyShopItemLimit shopItemLimit = m_storeModel.GetBuyShopLimit((uint)shopInfo.ID);
+ BuyShopItemLimit shopItemLimit = model.GetBuyShopLimit((uint)shopInfo.ID);
int remainNum = canBuyCnt;
if (shopItemLimit != null)
{
@@ -383,111 +372,99 @@
if (remainNum > 0)
{
- shopItemCell.itemCell.countText.text = StringUtility.Contact(remainNum.ToString(),
- "/" + canBuyCnt.ToString());
+ shopItemCell.itemCell.countText.text = StringUtility.Contact(remainNum, "/" + canBuyCnt);
shopItemCell.sellImage.gameObject.SetActive(false);
}
else
{
- shopItemCell.itemCell.countText.text = StringUtility.Contact(UIHelper.AppendStringColor(TextColType.Red, remainNum.ToString()),
- "/" + canBuyCnt.ToString());
+ var remainNumDescription = UIHelper.AppendStringColor(TextColType.Red, remainNum.ToString());
+ shopItemCell.itemCell.countText.text = StringUtility.Contact(remainNumDescription, "/", canBuyCnt);
shopItemCell.sellImage.gameObject.SetActive(true);
shopItemCell.stateImage.gameObject.SetActive(false);
}
}
- shopItemCell.itemNameText.color = UIHelper.GetUIColor(chinModel.ItemColor,true);
- shopItemCell.vipText.color = UIHelper.GetUIColor(TextColType.Black,true);
+ shopItemCell.itemNameText.color = UIHelper.GetUIColor(config.ItemColor, true);
+ shopItemCell.vipText.color = UIHelper.GetUIColor(TextColType.Black, true);
}
shopItemCell.LoadGuidEffectCtrl(shopInfo.ID, shopId);
}
shopItemCell.ShopCellBtn.RemoveAllListeners();
- shopItemCell.ShopCellBtn.AddListener(()=> {
- if(shopInfo.ID == shopId)
+ shopItemCell.ShopCellBtn.AddListener(() =>
+ {
+ if (shopInfo.ID == shopId)
{
shopId = 0;
shopItemCell.LoadGuidEffectCtrl(shopInfo.ID, shopId);
}
- m_storeModel.CloseRedPoint(shopInfo);
- m_storeModel.OnClickShopCell(shopInfo);
+ model.CloseRedPoint(shopInfo);
+ model.OnClickShopCell(shopInfo);
});
}
else
{
- cell.transform.GetChild(childCode).gameObject.SetActive(false);
+ cell.transform.GetChild(i).gameObject.SetActive(false);
}
}
}
- #region 鐐瑰嚮浜嬩欢
-
- private void OnClickIntegralStore()
+ private void OpenIntegralStore()
{
- m_storeModel.CloseAllRedpoint(StoreFunc.IntegralStore);
- m_storeModel.storeFuncType = StoreFunc.IntegralStore;
+ model.CloseAllRedpoint(StoreFunc.IntegralStore);
+ model.storeFuncType = StoreFunc.IntegralStore;
OnCreate();
- RefreshResetTime();
- functionOrder = _integralStoreTitle.order;
+ UpdateRefreshTime();
+ functionOrder = m_IntegralStoreTitle.order;
}
- private void OnClickBindStore()
+ private void OpenBindGoldStore()
{
- m_storeModel.CloseAllRedpoint(StoreFunc.BindStore);
- m_storeModel.storeFuncType = StoreFunc.BindStore;
+ model.CloseAllRedpoint(StoreFunc.BindStore);
+ model.storeFuncType = StoreFunc.BindStore;
OnCreate();
- RefreshResetTime();
- functionOrder = _bindStoreTitle.order;
+ UpdateRefreshTime();
+ functionOrder = m_BindStoreTitle.order;
}
- private void OnClickStrengthStore()
+ private void OpenStrengthStore()
{
- m_storeModel.CloseAllRedpoint(StoreFunc.GrowStrongerStore);
- m_storeModel.storeFuncType = StoreFunc.GrowStrongerStore;
+ model.CloseAllRedpoint(StoreFunc.GrowStrongerStore);
+ model.storeFuncType = StoreFunc.GrowStrongerStore;
OnCreate();
- RefreshResetTime();
- functionOrder = _growStrongerStoreTitle.order;
+ UpdateRefreshTime();
+ functionOrder = m_GrowStrongerStoreTitle.order;
}
- private void OnClickCommonStore()
+ private void OpenCommonStore()
{
- m_storeModel.CloseAllRedpoint(StoreFunc.CommonStore);
- m_storeModel.storeFuncType = StoreFunc.CommonStore;
+ model.CloseAllRedpoint(StoreFunc.CommonStore);
+ model.storeFuncType = StoreFunc.CommonStore;
OnCreate();
- RefreshResetTime();
- functionOrder = _commonStoreTitle.order;
+ UpdateRefreshTime();
+ functionOrder = m_CommonStoreTitle.order;
}
- private void OnClickWeekStore()
+ private void OpenMysteryStore()
{
- m_storeModel.CloseAllRedpoint(StoreFunc.WeekStore);
- m_storeModel.storeFuncType = StoreFunc.WeekStore;
+ model.CloseAllRedpoint(StoreFunc.MysteryStore);
+ model.storeFuncType = StoreFunc.MysteryStore;
OnCreate();
- RefreshResetTime();
- functionOrder = _weekStoreTitle.order;
+ UpdateRefreshTime();
+ functionOrder = m_WeekStoreTitle.order;
}
- private void OnClickRightBtn()
- {
- _funcBtnGroup.TriggerNext();
- }
-
- private void OnClickLeftBtn()
- {
- _funcBtnGroup.TriggerLast();
- }
-
- private void OnClickClose()
- {
- CloseImmediately();
- }
-
- private void ClickAssistBtn()
+ private void ViewAssistRecorders()
{
WindowJumpMgr.Instance.WindowJumpTo(JumpUIType.DungeonAssitCheckIn);
}
- #endregion
+
+ private void RefreshCommondities()
+ {
+ model.RefreshMysteryShop();
+ }
+
}
}
--
Gitblit v1.8.0