Skip to content

Commit

Permalink
fix: allow sandpaper to be used in deploying recipe (#7259)
Browse files Browse the repository at this point in the history
  • Loading branch information
VoidLeech authored Jan 10, 2025
1 parent fc94c75 commit d8310a6
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -551,7 +551,10 @@ public Recipe<? extends Container> getRecipe(ItemStack stack) {
ItemStack heldItemMainhand = player.getMainHandItem();
if (heldItemMainhand.getItem() instanceof SandPaperItem) {
sandpaperInv.setItem(0, stack);
return checkRecipe(AllRecipeTypes.SANDPAPER_POLISHING, sandpaperInv, level).orElse(null);
Optional<? extends Recipe<? extends Container>> polishingRecipe = checkRecipe(AllRecipeTypes.SANDPAPER_POLISHING, sandpaperInv, level);
if (polishingRecipe.isPresent()){
return polishingRecipe.get();
}
}

recipeInv.setItem(0, stack);
Expand Down

0 comments on commit d8310a6

Please sign in to comment.