|
@@ -19,7 +19,7 @@ namespace GFGEditor
|
|
|
public static void startScan()
|
|
|
{
|
|
|
ItemCfg[] dataArray = ItemCfgArray.Instance.dataArray;
|
|
|
- GetApproachCall[] actions = new GetApproachCall[] { GetClothingShopApproach, GetStoryLevelApproach, GetClothingSyntheticApproach, GetSuitGuideApproach, GetSuitSyntheticApproach, GetClothingDecomposeApproach, CheckGiftBagApproach, CheckShopExchangeApproach, CheckClothingFosterApproach, CheckDailyTaskApproach, GetZhaiXingApproach, GetLeaguePrayApproach, GetLeagueAnswerApproach };
|
|
|
+ GetApproachCall[] actions = new GetApproachCall[] { GetClothingShopApproach, GetStoryLevelApproach, CheckStoreApproach, GetClothingSyntheticApproach, GetSuitGuideApproach, GetSuitSyntheticApproach, GetClothingDecomposeApproach, CheckClothingFosterApproach, CheckDailyTaskApproach, GetZhaiXingApproach, GetLeaguePrayApproach, GetLeagueAnswerApproach };
|
|
|
Dictionary<SuitCfg, List<int>> suitDic = new Dictionary<SuitCfg, List<int>>();
|
|
|
int suitPartTotalCount = 0;
|
|
|
foreach (ItemCfg cfg in dataArray)
|
|
@@ -41,7 +41,7 @@ namespace GFGEditor
|
|
|
//套装
|
|
|
foreach (var a in suitDic)
|
|
|
{
|
|
|
- if(a.Key.isHide <= 0)
|
|
|
+ if (a.Key.isHide <= 0)
|
|
|
{
|
|
|
suitPartTotalCount += a.Value.Count;
|
|
|
}
|
|
@@ -80,7 +80,7 @@ namespace GFGEditor
|
|
|
{
|
|
|
return;
|
|
|
}
|
|
|
- if(itemCfg.itemType == ConstItemType.DRESS_UP)
|
|
|
+ if (itemCfg.itemType == ConstItemType.DRESS_UP)
|
|
|
{
|
|
|
suitDic.TryGetValue(suitCfg, out var partsList);
|
|
|
if (partsList == null)
|
|
@@ -95,6 +95,10 @@ namespace GFGEditor
|
|
|
|
|
|
private static void HandleItemApproch(ItemCfg cfg, GetApproachCall[] actions)
|
|
|
{
|
|
|
+ if (cfg.id == 3000001 || cfg.id == 3000002 || cfg.id == 3000003)
|
|
|
+ {
|
|
|
+ ET.Log.Debug("");
|
|
|
+ }
|
|
|
List<string> approachs = new List<string>();
|
|
|
foreach (GetApproachCall action in actions)
|
|
|
{
|
|
@@ -265,7 +269,7 @@ namespace GFGEditor
|
|
|
{
|
|
|
return null;
|
|
|
}
|
|
|
- if(itemCfg.itemType != ConstItemType.DRESS_UP)
|
|
|
+ if (itemCfg.itemType != ConstItemType.DRESS_UP)
|
|
|
{
|
|
|
return null;
|
|
|
}
|
|
@@ -407,44 +411,86 @@ namespace GFGEditor
|
|
|
return false;
|
|
|
}
|
|
|
/// <summary>
|
|
|
- /// 检测商城-礼包是否产出该物品
|
|
|
+ /// 检测商城-金卡是否产出该物品
|
|
|
/// </summary>
|
|
|
/// <param name="itemId"></param>
|
|
|
/// <returns></returns>
|
|
|
- private static string CheckGiftBagApproach(int itemId)
|
|
|
+ private static string CheckStoreApproach(int itemId)
|
|
|
{
|
|
|
- // GiftBagCfgArray manager = GiftBagCfgArray.Instance;
|
|
|
- // GiftBagCfg[] dataArray = manager.dataArray;
|
|
|
- // for (int i = 0; i < dataArray.Length; i++)
|
|
|
- // {
|
|
|
- // for (int j = 0; j < dataArray[i].itemsArr.Length; j++)
|
|
|
- // {
|
|
|
- // if (dataArray[i].itemsArr[j][0] == itemId)
|
|
|
- // {
|
|
|
- // return ConstFunctionId.SHOP_GIFT_BAG + "=1";
|
|
|
- // }
|
|
|
- // }
|
|
|
- // }
|
|
|
+ List<string> approachs = new List<string>();
|
|
|
+ List<ShopCfg> goldShopCfgs = ShopCfgArray.Instance.GetCfgsBymenu1Andmenu2(ConstStoreTabId.STORE_MONTH_CARD, ConstStoreSubId.STORE_MONTH_GOLD_CARD);
|
|
|
+ for (int i = 0; i < goldShopCfgs.Count; i++)
|
|
|
+ {
|
|
|
+ if (CheckIsHasItem(itemId, goldShopCfgs[i].itemId))
|
|
|
+ {
|
|
|
+ approachs.Add(ConstFunctionId.STORE + "=" + ConstStoreTabId.STORE_MONTH_CARD + "=" + ConstStoreSubId.STORE_MONTH_GOLD_CARD);
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ List<ShopCfg> blackShopCfgs = ShopCfgArray.Instance.GetCfgsBymenu1Andmenu2(ConstStoreTabId.STORE_MONTH_CARD, ConstStoreSubId.STORE_MONTH_BLACK_CARD);
|
|
|
+ for (int i = 0; i < blackShopCfgs.Count; i++)
|
|
|
+ {
|
|
|
+ if (CheckIsHasItem(itemId, blackShopCfgs[i].itemId))
|
|
|
+ {
|
|
|
+ approachs.Add(ConstFunctionId.STORE + "=" + ConstStoreTabId.STORE_MONTH_CARD + "=" + ConstStoreSubId.STORE_MONTH_BLACK_CARD);
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ List<ShopCfg> itemShopCfgs = ShopCfgArray.Instance.GetCfgsBymenu1Andmenu2(ConstStoreTabId.STORE_GIFT_BAG, ConstStoreSubId.STORE_GIFT_BAG_TIME_LIMIT);
|
|
|
+ for (int i = 0; i < itemShopCfgs.Count; i++)
|
|
|
+ {
|
|
|
+ if (CheckIsHasItem(itemId, itemShopCfgs[i].itemId))
|
|
|
+ {
|
|
|
+ approachs.Add(ConstFunctionId.STORE + "=" + ConstStoreTabId.STORE_GIFT_BAG + "=" + ConstStoreSubId.STORE_GIFT_BAG_TIME_LIMIT);
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ List<ShopCfg> greatestShopCfgs = ShopCfgArray.Instance.GetCfgsBymenu1Andmenu2(ConstStoreTabId.STORE_GIFT_BAG, ConstStoreSubId.STORE_GIFT_BAG_GREATEST);
|
|
|
+ for (int i = 0; i < greatestShopCfgs.Count; i++)
|
|
|
+ {
|
|
|
+ if (CheckIsHasItem(itemId, greatestShopCfgs[i].itemId))
|
|
|
+ {
|
|
|
+ approachs.Add(ConstFunctionId.STORE + "=" + ConstStoreTabId.STORE_GIFT_BAG + "=" + ConstStoreSubId.STORE_GIFT_BAG_GREATEST);
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ List<ShopCfg> exchangetShopCfgs = ShopCfgArray.Instance.GetCfgsBymenu1Andmenu2(ConstStoreTabId.STORE_EXCHANGE, ConstStoreSubId.STORE_EXCHANGE_LEAGUE);
|
|
|
+ for (int i = 0; i < exchangetShopCfgs.Count; i++)
|
|
|
+ {
|
|
|
+ if (CheckIsHasItem(itemId, exchangetShopCfgs[i].itemId))
|
|
|
+ {
|
|
|
+ approachs.Add(ConstFunctionId.STORE + "=" + ConstStoreTabId.STORE_EXCHANGE + "=" + ConstStoreSubId.STORE_EXCHANGE_LEAGUE);
|
|
|
+ break;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ if (approachs.Count > 0)
|
|
|
+ {
|
|
|
+ return string.Join(";", approachs);
|
|
|
+ }
|
|
|
return null;
|
|
|
}
|
|
|
- /// <summary>
|
|
|
- /// 检测商城-道具兑换是否产出该物品
|
|
|
- /// </summary>
|
|
|
- /// <param name="itemId"></param>
|
|
|
- /// <returns></returns>
|
|
|
- private static string CheckShopExchangeApproach(int itemId)
|
|
|
+ private static bool CheckIsHasItem(int itemId, int checkId)
|
|
|
{
|
|
|
- // ShopExchangeCfgArray manager = ShopExchangeCfgArray.Instance;
|
|
|
- // ShopExchangeCfg[] dataArray = manager.dataArray;
|
|
|
- // for (int i = 0; i < dataArray.Length; i++)
|
|
|
- // {
|
|
|
- // if (dataArray[i].itemId == itemId)
|
|
|
- // {
|
|
|
- // return ConstFunctionId.SHOP_EXCHANGE + "=2";
|
|
|
- // }
|
|
|
- // }
|
|
|
- return null;
|
|
|
+ ItemCfg itemCfg = ItemCfgArray.Instance.GetCfg(checkId);
|
|
|
+ if (itemCfg.itemType == ConstItemType.USEABLE)
|
|
|
+ {
|
|
|
+ for (int i = 0; i < itemCfg.itemsArr.Length; i++)
|
|
|
+ {
|
|
|
+ if (itemCfg.itemsArr[i][0] == itemId) return true;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else if (checkId == itemId)
|
|
|
+ {
|
|
|
+ return true;
|
|
|
+ }
|
|
|
+ return false;
|
|
|
}
|
|
|
+
|
|
|
/// <summary>
|
|
|
/// 检测服装升级是否产出该物品
|
|
|
/// </summary>
|
|
@@ -504,6 +550,11 @@ namespace GFGEditor
|
|
|
|
|
|
return null;
|
|
|
}
|
|
|
+ /// <summary>
|
|
|
+ /// 检测雅集福利是否产出该物品
|
|
|
+ /// </summary>
|
|
|
+ /// <param name="itemId"></param>
|
|
|
+ /// <returns></returns>
|
|
|
private static string GetLeaguePrayApproach(int itemId)
|
|
|
{
|
|
|
LeaguePrayCfg[] prayCfgs = LeaguePrayCfgArray.Instance.dataArray;
|
|
@@ -526,6 +577,11 @@ namespace GFGEditor
|
|
|
}
|
|
|
return null;
|
|
|
}
|
|
|
+ /// <summary>
|
|
|
+ /// 检测雅集答题是否产出该物品
|
|
|
+ /// </summary>
|
|
|
+ /// <param name="itemId"></param>
|
|
|
+ /// <returns></returns>
|
|
|
private static string GetLeagueAnswerApproach(int itemId)
|
|
|
{
|
|
|
LeagueQuestionCfg[] questionCfgs = LeagueQuestionCfgArray.Instance.dataArray;
|