From 6d7fe2f128b08709d432d743e9720b8ae81d56e3 Mon Sep 17 00:00:00 2001 From: Wofsauge Date: Thu, 11 Nov 2021 23:02:40 +0100 Subject: [PATCH 1/3] Removed Guppy eye pickup preview from path finding helper entity --- main.lua | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/main.lua b/main.lua index 2a0b1b8f..1be8617a 100644 --- a/main.lua +++ b/main.lua @@ -9,7 +9,7 @@ local game = Game() require("eid_config") EID.Config = EID.UserConfig EID.Config.Version = "3.2" -EID.ModVersion = "3.88" +EID.ModVersion = "3.89" EID.DefaultConfig.Version = EID.Config.Version EID.isHidden = false EID.player = nil @@ -497,13 +497,23 @@ end function EID:setPlayer() local p = Isaac.GetPlayer(0) - if p.SubType == PlayerType.PLAYER_THEFORGOTTEN_B then + if REPENTANCE and p.SubType == PlayerType.PLAYER_THEFORGOTTEN_B then EID.player = p:GetOtherTwin() else EID.player = p end end +if REPENTANCE then + function EID:removeWrongGuppyEyeInfo(effectEntity) + if EID.pathCheckerEntity ~= nil and effectEntity.Parent ~= nil then + if GetPtrHash(effectEntity.Parent) == GetPtrHash(EID.pathCheckerEntity) then + effectEntity:Remove() + end + end + end + EID:AddCallback(ModCallbacks.MC_POST_EFFECT_UPDATE, EID.removeWrongGuppyEyeInfo, EffectVariant.PICKUP_GHOST) +end --------------------------------------------------------------------------- ---------------------------On Update Function------------------------------ @@ -542,6 +552,7 @@ function EID:onGameUpdate() EID.pathCheckerEntity:ClearEntityFlags(EntityFlag.FLAG_APPEAR) EID.pathCheckerEntity:AddEntityFlags (EntityFlag.FLAG_PERSISTENT | EntityFlag.FLAG_NO_STATUS_EFFECTS | EntityFlag.FLAG_NO_SPRITE_UPDATE | EntityFlag.FLAG_HIDE_HP_BAR | EntityFlag.FLAG_NO_DEATH_TRIGGER) EID.pathCheckerEntity.EntityCollisionClass = EntityCollisionClass.ENTCOLL_NONE + EID.pathCheckerEntity.Visible = false EID.hasValidWalkingpath = false elseif not EID.pathCheckerEntity:Exists() then EID.pathCheckerEntity = nil From 09dcd449281fb82670424d67b99684131d6f615b Mon Sep 17 00:00:00 2001 From: Wofsauge Date: Fri, 12 Nov 2021 00:31:48 +0100 Subject: [PATCH 2/3] Made "Hide" key be able to be mapped to controllers --- eid_config.lua | 1 + main.lua | 2 +- metadata.xml | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/eid_config.lua b/eid_config.lua index 893b62c6..95968f69 100644 --- a/eid_config.lua +++ b/eid_config.lua @@ -51,6 +51,7 @@ EID.UserConfig = { ["Indicator"] = "none", -- Set the keybinding to toggle the descriptions -- look into the AB+ or Repentance documentation for the key names here: https://wofsauge.github.io/IsaacDocs/rep/enums/Keyboard.html + -- if you want to map it onto a controller button, you need to use the "ButtonAction" enum instead of the Keyboard enum https://wofsauge.github.io/IsaacDocs/rep/enums/ButtonAction.html -- Default = Keyboard.KEY_F2 ["HideKey"] = Keyboard.KEY_F2, -- Initial displaystate. Can be used to change the toggle behavior of the "Hide Key" event diff --git a/main.lua b/main.lua index 1be8617a..86cba044 100644 --- a/main.lua +++ b/main.lua @@ -591,7 +591,7 @@ local searchPartitions = EntityPartition.FAMILIAR + EntityPartition.ENEMY + Enti local function onRender(t) EID.isDisplaying = false - if Input.IsButtonTriggered(EID.Config["HideKey"], 0) then + if Input.IsButtonTriggered(EID.Config["HideKey"], EID.player.ControllerIndex or 0) then EID.isHidden = not EID.isHidden end if ModConfigMenu and ModConfigMenu.IsVisible and ModConfigMenu.Config["Mod Config Menu"].HideHudInMenu and EID.MCMCompat_isDisplayingEIDTab ~= "Visuals" then --if if the mod config menu exists, is opened and Hide Hud is enabled, and ModConfigMenu is currently in the "Visuals" tab of EID diff --git a/metadata.xml b/metadata.xml index f1f2101d..54714b1f 100644 --- a/metadata.xml +++ b/metadata.xml @@ -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 - 3.88 + 3.89 Public From 17f73f4bf2245171b4dd232d1b62312ecd19bfbf Mon Sep 17 00:00:00 2001 From: Wofsauge Date: Fri, 12 Nov 2021 00:51:59 +0100 Subject: [PATCH 3/3] Temporarily fixed item names using the variable name as their name, instead of the localization --- eid_api.lua | 12 ++++++++---- main.lua | 5 +++-- metadata.xml | 2 +- 3 files changed, 12 insertions(+), 7 deletions(-) diff --git a/eid_api.lua b/eid_api.lua index a404af64..d234d176 100644 --- a/eid_api.lua +++ b/eid_api.lua @@ -436,14 +436,18 @@ function EID:getObjectName(Type, Variant, SubType) end end if tableName == "collectibles" then - return name or EID.itemConfig:GetCollectible(SubType).Name + local vanillaName = EID.itemConfig:GetCollectible(SubType).Name + return name or (not string.find(vanillaName, "^#") and vanillaName) or EID.descriptions["en_us"][tableName][SubType][2] or vanillaName elseif tableName == "trinkets" then - return name or EID.itemConfig:GetTrinket(SubType).Name + local vanillaName = EID.itemConfig:GetTrinket(SubType).Name + return name or (not string.find(vanillaName, "^#") and vanillaName) or EID.descriptions["en_us"][tableName][SubType][2] or vanillaName elseif tableName == "cards" then - return name or EID.itemConfig:GetCard(SubType).Name + local vanillaName = EID.itemConfig:GetCard(SubType).Name + return name or (not string.find(vanillaName, "^#") and vanillaName) or EID.descriptions["en_us"][tableName][SubType][2] or vanillaName elseif tableName == "pills" or tableName == "horsepills" then local adjustedSubtype = EID:getAdjustedSubtype(Type, Variant, SubType) - name = name or EID.itemConfig:GetPillEffect(adjustedSubtype - 1).Name + local vanillaName = EID.itemConfig:GetPillEffect(adjustedSubtype - 1).Name + name = name or (not string.find(vanillaName, "^#") and vanillaName) or EID.descriptions["en_us"][tableName][SubType][2] or vanillaName return string.gsub(name,"I'm Excited!!!","I'm Excited!!") -- prevent markup trigger elseif tableName == "sacrifice" then return EID:getDescriptionEntry("sacrificeHeader") diff --git a/main.lua b/main.lua index 86cba044..026f8366 100644 --- a/main.lua +++ b/main.lua @@ -9,7 +9,7 @@ local game = Game() require("eid_config") EID.Config = EID.UserConfig EID.Config.Version = "3.2" -EID.ModVersion = "3.89" +EID.ModVersion = "3.90" EID.DefaultConfig.Version = EID.Config.Version EID.isHidden = false EID.player = nil @@ -591,6 +591,8 @@ local searchPartitions = EntityPartition.FAMILIAR + EntityPartition.ENEMY + Enti local function onRender(t) EID.isDisplaying = false + EID:setPlayer() + if Input.IsButtonTriggered(EID.Config["HideKey"], EID.player.ControllerIndex or 0) then EID.isHidden = not EID.isHidden end @@ -602,7 +604,6 @@ local function onRender(t) -- Disabling Achievement detection for now, since it breaks on some occasions since new patch --renderAchievementInfo() - EID:setPlayer() if EID.GameVersion == "ab+" then if EID.player:HasCollectible(CollectibleType.COLLECTIBLE_SCHOOLBAG) then EID:addTextPosModifier("Schoolbag", Vector(0,30)) diff --git a/metadata.xml b/metadata.xml index 54714b1f..02a31ce8 100644 --- a/metadata.xml +++ b/metadata.xml @@ -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 - 3.89 + 3.90 Public