Added recipe skipping when pressing c if it is not unlocked

master
Mohammad Shoaib 2022-04-05 17:37:09 +05:30
parent afc54a0eef
commit 025956f66c
1 changed files with 4 additions and 0 deletions

View File

@ -1144,6 +1144,10 @@ namespace stardew_access.Patches
__instance.setCurrentlySnappedComponentTo(pagesOfCraftingRecipes[___currentCraftingPage].ElementAt(currentSelectedCraftingRecipe).Key.myID); __instance.setCurrentlySnappedComponentTo(pagesOfCraftingRecipes[___currentCraftingPage].ElementAt(currentSelectedCraftingRecipe).Key.myID);
pagesOfCraftingRecipes[___currentCraftingPage].ElementAt(currentSelectedCraftingRecipe).Key.snapMouseCursorToCenter(); pagesOfCraftingRecipes[___currentCraftingPage].ElementAt(currentSelectedCraftingRecipe).Key.snapMouseCursorToCenter();
// Skip if recipe is not unlocked/unknown
if (pagesOfCraftingRecipes[___currentCraftingPage].ElementAt(currentSelectedCraftingRecipe).Key.hoverText.Equals("ghosted"))
CycleThroughRecipies(pagesOfCraftingRecipes, ___currentCraftingPage, __instance);
} }
// This method is used to get the inventory items to check if the player has enough ingredients for a recipe // This method is used to get the inventory items to check if the player has enough ingredients for a recipe