From a015513a07d6daff0fd6f73dc545e28148d3b9be Mon Sep 17 00:00:00 2001 From: Buurazu Date: Sat, 22 Jan 2022 14:05:59 -0500 Subject: [PATCH] revert pathchecker --- main.lua | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/main.lua b/main.lua index aee11650..ea15e3e4 100644 --- a/main.lua +++ b/main.lua @@ -787,6 +787,17 @@ function EID:setPlayer() end end +-- is this needed if pathchecker uses a no reward seed? +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------------------------------ @@ -834,8 +845,8 @@ function EID:onGameUpdate() return end if EID.pathCheckerEntity == nil then - -- Spawns an Ultra Greed Door and makes it invisible and intangible to act as a Pathfinding NPC that can't be rerolled and has no AI - EID.pathCheckerEntity = game:Spawn(294, 0, EID.player.Position, nullVector, EID.player, 0, 0) + -- Spawns the EID Helper entity with seed that doesnt spawn rewards + EID.pathCheckerEntity = game:Spawn(17, 3169, EID.player.Position, nullVector, EID.player, 0, 4354) 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 | EntityFlag.FLAG_FRIENDLY) if REPENTANCE then EID.pathCheckerEntity:AddEntityFlags(EntityFlag.FLAG_NO_QUERY) end