diff --git a/popcorn/Assets/MyGame/Scenes/DebugOption/Scripts/DebugOptionManager.cs b/popcorn/Assets/MyGame/Scenes/DebugOption/Scripts/DebugOptionManager.cs index 27c783e6..22e72393 100644 --- a/popcorn/Assets/MyGame/Scenes/DebugOption/Scripts/DebugOptionManager.cs +++ b/popcorn/Assets/MyGame/Scenes/DebugOption/Scripts/DebugOptionManager.cs @@ -98,7 +98,7 @@ public class DebugOptionManager : MonoBehaviour // 所持素材 gameData.Material.Clear(); // レシピ - gameData.MyRecipes = GetMyRecipe(gameData.ViewedShopLevel); + gameData.MyRecipes = GetMyRecipe(gameData.ViewedShopLevel, true); // フライパン gameData.Pans = new[] { Const.DefaultPanId }; }).AddTo(this); @@ -369,12 +369,15 @@ public class DebugOptionManager : MonoBehaviour }).AddTo(this); } - private static int[] GetMyRecipe(int level) + private static int[] GetMyRecipe(int level, bool clearShopRecipe = false) { - var shopLevelList = SpreadsheetDataManager.Instance.GetBaseDataList(Const.ShopLevelDataSheet); - return GameDataManager.GameData.MyRecipes.Except(shopLevelList.Select(data => data.id)) - .Union(shopLevelList.Where(data => data.shopLevel <= level).Select(data => data.id)) - .ToArray(); + var productList = SpreadsheetDataManager.Instance.GetBaseDataList(Const.ProductDataSheet); + var levelUpAchievedList = productList.Where(data => data.shopLevel != Const.SpecialShopLevel).ToList(); + var levelUpAchievedRecipeList = levelUpAchievedList.Where(data => data.shopLevel <= level).Select(data => data.id); + var shopRecipe = clearShopRecipe + ? GameDataManager.GameData.MyRecipes.Except(levelUpAchievedList.Select(data => data.id)) + : Array.Empty(); + return levelUpAchievedRecipeList.Union(shopRecipe).ToArray(); } #endif }