From cec8b67d82c2c2c1662d55c818c4a46bcc0487db Mon Sep 17 00:00:00 2001
From: yyl <yyl>
Date: 星期一, 25 八月 2025 17:36:02 +0800
Subject: [PATCH] 125 【战斗】战斗系统 战斗技能
---
Main/System/Store/StoreModel.cs | 53 +++++++++++------------------------------------------
1 files changed, 11 insertions(+), 42 deletions(-)
diff --git a/Main/System/Store/StoreModel.cs b/Main/System/Store/StoreModel.cs
index 17c4166..63460e9 100644
--- a/Main/System/Store/StoreModel.cs
+++ b/Main/System/Store/StoreModel.cs
@@ -28,13 +28,11 @@
public class StoreModel : GameSystemManager<StoreModel>
{
- public int[] normalBuyCoinsTypes { get; private set; }
public string UNIONSTORESAVE_KEY { get; private set; }
public string MUSTBUYSAVE_KEY { get; private set; }
public string StoreEffectRecord_Key { get; private set; }
public Dictionary<int, Dictionary<int, int>> JobReplaceIdDict = new Dictionary<int, Dictionary<int, int>>();
- public Dictionary<int, string> resetTimeDict { get; private set; }
- public Dictionary<int, int> showCoinsUIDict { get; private set; }
+ public Dictionary<int, int> showCoinUIDict { get; private set; }
public int storeTrailerLv { get; private set; }
@@ -65,22 +63,13 @@
//鎺掕姒滄椿鍔ㄧ殑鍟嗗簵
public int rankActStore_MoneyType;
public int rankActStore_StoreType;
- public Operation rankActStore_ActType;
+ public OperationType rankActStore_ActType;
public override void Init()
{
ParseFuncConfig();
ParseStoreConfig();
SetShopRedpoint();
- FuncConfigConfig buyItemHinit = FuncConfigConfig.Get("BuyItemHinit");
- normalBuyCoinsTypes = ConfigParse.GetMultipleStr<int>(buyItemHinit.Numerical1);
- FuncConfigConfig restTimeConfig = FuncConfigConfig.Get("RefreshText");
- resetTimeDict = ConfigParse.GetDic<int, string>(restTimeConfig.Numerical1);
- FuncConfigConfig mallCurrency = FuncConfigConfig.Get("MallCurrency");
- showCoinsUIDict = ConfigParse.GetDic<int, int>(mallCurrency.Numerical1);
- FuncConfigConfig mallPush = FuncConfigConfig.Get("MallPush");
- storeTrailerLv = int.Parse(mallPush.Numerical1);
-
}
public void OnBeforePlayerDataInitialize()
@@ -677,19 +666,7 @@
}
#endregion
- public string GetStoreRefreshTimeByType(int type)
- {
- if (resetTimeDict == null || !resetTimeDict.ContainsKey(type)) return string.Empty;
- switch (type)
- {
- case 7:
- int willRefreshTime = GetWillRefreshTime();
- return Language.Get(resetTimeDict[type], UIHelper.AppendColor(TextColType.Green, TimeUtility.SecondsToHMS(willRefreshTime), true));
- default:
- return Language.Get(resetTimeDict[type]);
- }
- }
public string GetMysteryStoreRefreshTime()
{
@@ -934,7 +911,7 @@
public void OnClickShopCell(StoreConfig shopInfo)
{
int itemId = GetReplaceId(shopInfo.ID, shopInfo.ItemID);
- ItemTipUtility.ShowGood(shopInfo.ID, itemId);
+ ItemTipUtility.Show(itemId);
}
public int BuyCnt { get; private set; }
@@ -1056,28 +1033,15 @@
public void GetBuyResult(HA811_tagMCShoppingResult result)
{
- Debug.Log("GetBuyResult");
+ //Debug.Log("GetBuyResult");
StoreConfig tagStore = StoreConfig.Get((int)result.ItemIndex);
if (tagStore != null)
{
ItemConfig chinModel = ItemConfig.Get(GetReplaceId(tagStore.ID, tagStore.ItemID));
- if (!normalBuyCoinsTypes.Contains(tagStore.MoneyType))
+ if (tagStore.RemindSuccess == 0)
{
- if (tagStore.RemindSuccess == 0)
- {
- return;
- }
- // BuySuccessModel.Instance.SetBuySuccessModel(chinModel.ID, (int)result.ItemCnt);
- // if (!WindowCenter.Instance.IsOpen<BuySuccessWin>())
- // {
- // WindowCenter.Instance.Open<BuySuccessWin>();
- // }
- }
- else
- {
- float costMoney = tagStore.MoneyNumber;
- SysNotifyMgr.Instance.ShowTip("BuyItemHinit", costMoney, tagStore.MoneyType, chinModel.ItemName);
+ return;
}
if (RefreshBuyResultEvent != null)
@@ -1507,6 +1471,11 @@
{
var redable = false;
var config = StoreConfig.Get(shopId);
+ if (config == null)
+ {
+ Debug.LogError($"StoreConfig {shopId} is null");
+ continue;
+ }
switch (config.ShopType)
{
case 8:
--
Gitblit v1.8.0