From ce5dc1daf0a103ea3728e1848264f48198cbcc25 Mon Sep 17 00:00:00 2001 From: Buurazu Date: Wed, 23 Feb 2022 22:10:49 -0500 Subject: [PATCH 1/2] Update eid_bagofcrafting.lua --- eid_bagofcrafting.lua | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/eid_bagofcrafting.lua b/eid_bagofcrafting.lua index c443533d..94499797 100644 --- a/eid_bagofcrafting.lua +++ b/eid_bagofcrafting.lua @@ -513,8 +513,7 @@ local moddedCrafting = false -- Check for modded items past the known max item ID on game start (can also support game updates) -- Only works if the new items are at Weight 1.0 in their item pools, but better than nothing local function GameStartCrafting() - if EID.Config["BagOfCraftingModdedRecipes"] and not EID:PlayersHaveCollectible(CollectibleType.COLLECTIBLE_TMTRAINER) and EID.itemConfig:GetCollectible(EID.XMLMaxItemID+1) ~= nil then - dofile(EID.modPath .. "eid_xmldata.lua") + if EID.Config["BagOfCraftingModdedRecipes"] and not EID:PlayersHaveCollectible(CollectibleType.COLLECTIBLE_TMTRAINER) and EID.itemConfig:GetCollectible(EID.XMLMaxItemID+1) ~= nil and not moddedCrafting then -- Items past max ID detected CraftingMaxItemID = EID.XMLMaxItemID -- XMLMaxItemID is never modified -- Add new item qualities @@ -540,11 +539,6 @@ local function GameStartCrafting() end moddedCrafting = true sortNeeded = true - elseif moddedCrafting then - -- we had modded items; they have since been disabled - dofile(EID.modPath .. "eid_xmldata.lua") - moddedCrafting = false - sortNeeded = true end end EID:AddCallback(ModCallbacks.MC_POST_GAME_STARTED, GameStartCrafting) From cfa6f73932c2eccad5433fcf4215eb337a372641 Mon Sep 17 00:00:00 2001 From: Buurazu Date: Wed, 23 Feb 2022 22:11:09 -0500 Subject: [PATCH 2/2] Fix mods making REPENTANCE = false --- main.lua | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/main.lua b/main.lua index eda13053..4c783d12 100644 --- a/main.lua +++ b/main.lua @@ -826,6 +826,11 @@ EID.RecheckVoid = false function EID:onGameUpdate() EID.GameUpdateCount = EID.GameUpdateCount + 1 EID:checkPlayersForMissingItems() + + -- Fix some outdated mods erroneously setting the REPENTANCE constant to false + if EID.GameVersion == "rep" and REPENTANCE == false then + REPENTANCE = true + end if collSpawned then collSpawned = false