From b488dc4186a0b00958fc03c71d02e5466394271a Mon Sep 17 00:00:00 2001 From: Josh Retzer Date: Fri, 19 Jun 2026 03:15:17 -0700 Subject: [PATCH] use rgon to calculate bag of crafting (#968) --- features/eid_bagofcrafting.lua | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/features/eid_bagofcrafting.lua b/features/eid_bagofcrafting.lua index 7c95b726..52968463 100644 --- a/features/eid_bagofcrafting.lua +++ b/features/eid_bagofcrafting.lua @@ -233,6 +233,18 @@ function EID:calculateBagOfCrafting(componentsTable) table.sort(components) local componentsAsString = table.concat(components, ",") + -- calculate the game's actual output, including any modifications to recipes.xml + if REPENTOGON and EntityPlayer.CalculateBagOfCraftingOutput then + local cacheResult = calculatedRecipes[componentsAsString] + if cacheResult ~= nil then + return cacheResult + end + + local collectible, itemPool = EntityPlayer.CalculateBagOfCraftingOutput(components) + calculatedRecipes[componentsAsString] = collectible + return collectible + end + -- Check the fixed recipes local cacheResult = CraftingFixedRecipes[componentsAsString] if cacheResult ~= nil then