From c2a2b14425a293916ac5271fcf88868156a8bfe2 Mon Sep 17 00:00:00 2001 From: wendavid552 Date: Fri, 19 Jan 2024 07:13:03 +0800 Subject: [PATCH] :bug: Fix Stonecutter recipe with DynamaticRegistryManager --- .../java/fi/dy/masa/itemscroller/util/InventoryUtils.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/main/java/fi/dy/masa/itemscroller/util/InventoryUtils.java b/src/main/java/fi/dy/masa/itemscroller/util/InventoryUtils.java index f8222d0fd..7e128a439 100644 --- a/src/main/java/fi/dy/masa/itemscroller/util/InventoryUtils.java +++ b/src/main/java/fi/dy/masa/itemscroller/util/InventoryUtils.java @@ -21,6 +21,7 @@ import fi.dy.masa.itemscroller.villager.VillagerDataStorage; import fi.dy.masa.itemscroller.villager.VillagerUtils; import fi.dy.masa.malilib.util.GuiUtils; +import net.minecraft.registry.DynamicRegistryManager; import org.apache.commons.lang3.StringUtils; import it.unimi.dsi.fastutil.ints.IntArrayList; import it.unimi.dsi.fastutil.ints.IntComparator; @@ -1349,9 +1350,10 @@ public static int getStonecuttingRecipeFromPattern(RecipePattern recipe) { search.setStack(i, items[i]); } List inputRecipes = recipeManager.getAllMatches(RecipeType.STONECUTTING, search, mc.world); + DynamicRegistryManager stonecuttingRegistryManger = mc.world.getRegistryManager(); for(int i=0; i