Improved compatibility with AB+ and deactivated Achievement warning for that DLC
This commit is contained in:
1 parent
1a22c0083d
commit
751df4c3bb
3 files changed
+8
-9
No files matched your search
+5
-6
@@ -776,7 +776,6 @@ end
|
||||
local maxCollectibleID = nil
|
||||
function EID:isCollectibleUnlocked(collectibleID, itemPoolOfItem)
|
||||
local itemPool = Game():GetItemPool()
|
||||
--local itemConfig = Isaac.GetItemConfig()
|
||||
if (not maxCollectibleID) then maxCollectibleID = EID:GetMaxCollectibleID() end
|
||||
for i= 1, maxCollectibleID do
|
||||
if ItemConfig.Config.IsValidCollectible(i) and i ~= collectibleID then
|
||||
@@ -785,7 +784,7 @@ function EID:isCollectibleUnlocked(collectibleID, itemPoolOfItem)
|
||||
end
|
||||
local isUnlocked = false
|
||||
for i = 0,1 do -- some samples to make sure
|
||||
local collID = itemPool:GetCollectible(itemPoolOfItem, false)
|
||||
local collID = itemPool:GetCollectible(itemPoolOfItem, false, 1)
|
||||
if collID == collectibleID then
|
||||
isUnlocked = true
|
||||
break
|
||||
@@ -799,18 +798,18 @@ function EID:isCollectibleUnlockedAnyPool(collectibleID)
|
||||
local item = EID.itemConfig:GetCollectible(collectibleID)
|
||||
if EID.itemUnlockStates[collectibleID] == nil then
|
||||
--whitelist all quest items and items with no associated achievement
|
||||
if (item.AchievementID == -1 or item.Tags & ItemConfig.TAG_QUEST == ItemConfig.TAG_QUEST) then
|
||||
if item.AchievementID == -1 or (item.Tags and item.Tags & ItemConfig.TAG_QUEST == ItemConfig.TAG_QUEST) then
|
||||
EID.itemUnlockStates[collectibleID] = true
|
||||
return true
|
||||
end
|
||||
--blacklist all hidden items
|
||||
if (item.Hidden) then
|
||||
if item.Hidden then
|
||||
EID.itemUnlockStates[collectibleID] = false
|
||||
return false
|
||||
end
|
||||
--iterate through the pools this item can be in
|
||||
for k,v in ipairs(EID.CollectiblesPools[collectibleID]) do
|
||||
if (EID:isCollectibleUnlocked(collectibleID, v)) then
|
||||
for k,itemPoolID in ipairs(EID.CollectiblesPools[collectibleID]) do
|
||||
if (itemPoolID < ItemPoolType.NUM_ITEMPOOLS and EID:isCollectibleUnlocked(collectibleID, itemPoolID)) then
|
||||
EID.itemUnlockStates[collectibleID] = true
|
||||
return true
|
||||
end
|
||||
|
||||
@@ -9,7 +9,7 @@ local game = Game()
|
||||
require("eid_config")
|
||||
EID.Config = EID.UserConfig
|
||||
EID.Config.Version = "3.2"
|
||||
EID.ModVersion = "3.84"
|
||||
EID.ModVersion = "3.85"
|
||||
EID.DefaultConfig.Version = EID.Config.Version
|
||||
EID.isHidden = false
|
||||
EID.player = nil
|
||||
@@ -537,7 +537,7 @@ EID:AddCallback(ModCallbacks.MC_POST_UPDATE, EID.onGameUpdate)
|
||||
|
||||
local hasShownAchievementWarning = false
|
||||
local function renderAchievementInfo()
|
||||
if game:GetFrameCount() < 10*30 then
|
||||
if REPENTANCE and game:GetFrameCount() < 10*30 then
|
||||
local hasCubeOfMeatUnlocked = EID:isCollectibleUnlockedAnyPool(CollectibleType.COLLECTIBLE_CUBE_OF_MEAT)
|
||||
if not hasCubeOfMeatUnlocked then
|
||||
local demoDescObj = EID:getDescriptionObj(-999, -1, 1)
|
||||
|
||||
+1
-1
@@ -90,7 +90,7 @@ https://moddingofisaac.com/mod/1079/external-item-descriptions
|
||||
- Jake for the sweet [b]German[/b] language pack
|
||||
- [url=https://steamcommunity.com/id/whytefang/]adc[/url] for creating an awesome new Languagepack and providing ideas for new functionalities
|
||||
</description>
|
||||
<version>3.84</version>
|
||||
<version>3.85</version>
|
||||
<visibility>Public</visibility>
|
||||
<tag id="Lua"/>
|
||||
<tag id="Items"/>
|
||||
|
||||
Reference in new issue
Block a user