From 4e12773d626ebaf4a92f4ee9fce5bea31e3716b8 Mon Sep 17 00:00:00 2001 From: Wofsauge Date: Sat, 13 Jan 2024 17:13:43 +0100 Subject: [PATCH] Fixed errors when using collection page display with modded items --- eid_repentogon.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/eid_repentogon.lua b/eid_repentogon.lua index 2db0a4a0..06367191 100644 --- a/eid_repentogon.lua +++ b/eid_repentogon.lua @@ -66,12 +66,12 @@ function EID:OnMenuRender() local selectedPage = CollectionMenu.GetSelectedPage() local CollectibleId = selectedPage * (20 * 6) + CollectionMenu.GetSelectedElement() + 1 for _, id in ipairs(skipItemIDs) do -- some items dont exist, so we need to "skip" those when counting - if id < CollectibleId then + if id <= CollectibleId then CollectibleId = CollectibleId + 1 end end - local demoDescObj = EID:getDescriptionObj(5, 100, CollectibleId) - if not Isaac.GetPersistentGameData():IsItemInCollection(CollectibleId) then + local demoDescObj = EID:getDescriptionObj(5, 100, CollectibleId, nil, false) + if CollectibleId < CollectibleType.NUM_COLLECTIBLES and not Isaac.GetPersistentGameData():IsItemInCollection(CollectibleId) then EID:renderQuestionMark(nil) return end