funcs to handle generic item markup + reorganize loc tables + misc (#681)
* RIP tear delay multiplier, and reorganizing * moving things around and adding things * Move black feather items table * Improve Black Feather, change Black Rune's detection * Fix bugs with cheat/rep only modifiers * New generic PlayersHaveItem function stuff * Change Collectible checks to generic Item checks * Update eid_conditionals.lua * Tear multiplier -> Tears multiplier * Tear -> Tears multiplier * BFFs overhaul * BFFs overhaul * NoEffect changed * NoEffect changed * Add SelfConditional, BFFs check, find+replace can also append * Remove BFFs modifier * BFFs + started work on self-noeffects * Added blinkpink, working on BFFs/hivemind * repentance flies * some rep familiars checked
This commit is contained in:
1 parent
7e2959a891
commit
a023ec2fff
10 files changed
+639
-374
No files matched your search
+128
-6
@@ -301,6 +301,7 @@ function EID:getTableName(Type, Variant, SubType)
|
||||
end
|
||||
elseif idString == "-999.-1" then return "sacrifice"
|
||||
elseif idString == "1000.76" then return "dice"
|
||||
elseif idString == "1.0" then return "players"
|
||||
else return "custom"
|
||||
end
|
||||
end
|
||||
@@ -610,6 +611,8 @@ function EID:getObjectName(Type, Variant, SubType)
|
||||
return EID:getDescriptionEntry("sacrificeHeader").." ("..SubType.."/"..#EID.descriptions["en_us"].sacrifice..")"
|
||||
elseif tableName == "dice" then
|
||||
return EID:getDescriptionEntry("diceHeader").." ("..SubType..")"
|
||||
elseif tableName == "players" then
|
||||
return EID:getPlayerName(SubType)
|
||||
elseif tableName == "custom" then
|
||||
local xmlName = EID:GetEntityXMLName(Type, Variant, SubType)
|
||||
return name or xmlName or Type.."."..Variant.."."..SubType
|
||||
@@ -733,7 +736,12 @@ function EID:replaceNameMarkupStrings(text)
|
||||
for e in string.gmatch(strTrimmed, "([^.]*)") do
|
||||
table.insert(entityID, tonumber(e))
|
||||
end
|
||||
name = EID:getObjectName(entityID[1], entityID[2], entityID[3])
|
||||
local iconText = ""
|
||||
if showIcon then
|
||||
if entityID[1] == 1 then iconText = "{{Player" .. entityID[3] .. "}} "
|
||||
else iconText = "{{" .. EID:GetIconNameByVariant(entityID[2]) .. entityID[3] .. "}} " end
|
||||
end
|
||||
name = iconText .. EID:getObjectName(entityID[1], entityID[2], entityID[3])
|
||||
elseif indicator == "C" then -- Collectible
|
||||
name = (showIcon and "{{Collectible"..id.."}} " or "")..EID:getObjectName(5, 100, id)
|
||||
elseif indicator == "T" then -- Trinket
|
||||
@@ -780,9 +788,24 @@ end
|
||||
-- Tries to read special markup used to generate icons for all Collectibles/Trinkets and the default Cards/Pills
|
||||
-- Returns an inlineIcon Object or nil if no parsing was possible
|
||||
function EID:createItemIconObject(str)
|
||||
local collID,numReplace = string.gsub(str, "Collectible", "")
|
||||
local item = nil
|
||||
local subTypeIdentifier = 0
|
||||
|
||||
-- Check for {{Item#.##.###}} markup; easiest way to handle it is to just call this function again
|
||||
local itemID,numReplaceGeneric = string.gsub(str, "Item", "")
|
||||
if numReplaceGeneric > 0 and itemID ~= "" then
|
||||
local Type, Var, Sub = EID:SplitTVS(itemID)
|
||||
if Type == 1 then return EID:getIcon("Player" .. Sub)
|
||||
elseif Type == 5 then
|
||||
if Var == 100 then return EID:createItemIconObject("Collectible" .. Sub)
|
||||
elseif Var == 350 then return EID:createItemIconObject("Trinket" .. Sub)
|
||||
elseif Var == 300 then return EID:createItemIconObject("Card" .. Sub)
|
||||
elseif Var == 70 then return EID:createItemIconObject("Pill" .. Sub)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
local collID,numReplace = string.gsub(str, "Collectible", "")
|
||||
if numReplace > 0 and collID ~= "" and tonumber(collID) ~= nil then
|
||||
item = EID.itemConfig:GetCollectible(tonumber(collID))
|
||||
subTypeIdentifier = tonumber(collID)
|
||||
@@ -1163,38 +1186,137 @@ function EID:updateDescriptionsViaTable(changeTable, tableToUpdate)
|
||||
end
|
||||
end
|
||||
|
||||
-- Converts e.g. "5.100.69" format strings into 5, 100, and 69; returns 0 for any not included
|
||||
function EID:SplitTVS(tvsString)
|
||||
local Type, Var, Sub = 0, 0, 0
|
||||
local tvsTable = {}
|
||||
for i in string.gmatch(tvsString, "[^.]+") do table.insert(tvsTable, tonumber(i)) end
|
||||
Type = tvsTable[1] or Type; Var = tvsTable[2] or Var; Sub = tvsTable[3] or Sub;
|
||||
return Type, Var, Sub
|
||||
end
|
||||
|
||||
-- Checks if any player has a given item ID (or anyone is a given player ID)
|
||||
function EID:PlayersHaveItem(Type, Var, Sub)
|
||||
-- convert "5.100.69" format strings into type, var, sub
|
||||
if type(Type) == "string" then
|
||||
Type, Var, Sub = EID:SplitTVS(Type)
|
||||
-- assume collectible if only Type was given
|
||||
elseif Var == nil then Sub = Type; Type = 5; Var = 100 end
|
||||
if Type == 1 then return EID:PlayersHaveCharacter(Sub)
|
||||
elseif Type == 5 then
|
||||
if Var == 100 then return EID:PlayersHaveCollectible(Sub)
|
||||
elseif Var == 350 then return EID:PlayersHaveTrinket(Sub)
|
||||
elseif Var == 300 then return EID:PlayersHaveCard(Sub)
|
||||
elseif Var == 70 then return EID:PlayersHavePill(Sub)
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
||||
-- Checks if the given player has the given item ID (or is the given player ID)
|
||||
function EID:PlayerHasItem(player, Type, Var, Sub)
|
||||
-- convert "5.100.69" format strings into type, var, sub
|
||||
if type(Type) == "string" then
|
||||
Type, Var, Sub = EID:SplitTVS(Type)
|
||||
-- assume collectible if only Type was given
|
||||
elseif Var == nil then Sub = Type; Type = 5; Var = 100 end
|
||||
if Type == 1 then return player:GetPlayerType() == Sub
|
||||
elseif Type == 5 then
|
||||
if Var == 100 then return player:HasCollectible(Sub)
|
||||
elseif Var == 350 then return player:HasTrinket(Sub)
|
||||
elseif Var == 300 then return EID:PlayerHasCard(player, Sub)
|
||||
elseif Var == 70 then return EID:PlayerHasPill(player, Sub)
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
||||
-- Checks if any player has a given collectible ID, for modifiers
|
||||
function EID:PlayersHaveCollectible(collectibleID)
|
||||
for i = 0, game:GetNumPlayers() - 1 do
|
||||
local player = Isaac.GetPlayer(i)
|
||||
if player:HasCollectible(collectibleID) then
|
||||
return true, player
|
||||
return true, player, i
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
||||
function EID:PlayersVoidedCollectible(collectibleID)
|
||||
for i = 0, game:GetNumPlayers() - 1 do
|
||||
local player = Isaac.GetPlayer(i)
|
||||
if player:HasCollectible(477) and EID.absorbedItems[tostring(i)] and EID.absorbedItems[tostring(i)][tostring(collectibleID)] then
|
||||
return true, player, i
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
function EID:PlayerVoidedCollectible(player, collectibleID)
|
||||
local i = EID:getPlayerID(player)
|
||||
if player:HasCollectible(477) and EID.absorbedItems[tostring(i)] and EID.absorbedItems[tostring(i)][tostring(collectibleID)] then
|
||||
return true
|
||||
end
|
||||
end
|
||||
|
||||
-- Checks if any player has a given trinket ID, for modifiers
|
||||
function EID:PlayersHaveTrinket(trinketID)
|
||||
for i = 0, game:GetNumPlayers() - 1 do
|
||||
local player = Isaac.GetPlayer(i)
|
||||
if player:HasTrinket(trinketID) then
|
||||
return true, player
|
||||
return true, player, i
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
||||
function EID:PlayersHaveCard(cardID)
|
||||
for i = 0, game:GetNumPlayers() - 1 do
|
||||
local player = Isaac.GetPlayer(i)
|
||||
for j = 0, (EID.isRepentance and 3 or 1) do
|
||||
if player:GetCard(j) == cardID then
|
||||
return true, player, i
|
||||
end
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
function EID:PlayerHasCard(player, cardID)
|
||||
for j = 0, (EID.isRepentance and 3 or 1) do
|
||||
if player:GetCard(j) == cardID then
|
||||
return true
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function EID:PlayersHavePill(pillID)
|
||||
for i = 0, game:GetNumPlayers() - 1 do
|
||||
local player = Isaac.GetPlayer(i)
|
||||
for j = 0, (EID.isRepentance and 3 or 1) do
|
||||
if player:GetPill(j) == pillID then
|
||||
return true, player, i
|
||||
end
|
||||
end
|
||||
end
|
||||
return false
|
||||
end
|
||||
function EID:PlayerHasPill(player, pillID)
|
||||
for j = 0, (EID.isRepentance and 3 or 1) do
|
||||
if player:GetPill(j) == pillID then
|
||||
return true
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
-- Checks if someone is playing as a certain character, for modifiers
|
||||
-- includeTainted means we don't care if the player is Tainted or not (for things that, say, apply to Lost/Tainted Lost)
|
||||
function EID:PlayersHaveCharacter(playerType, includeTainted)
|
||||
for i = 0, game:GetNumPlayers() - 1 do
|
||||
local player = Isaac.GetPlayer(i)
|
||||
if player:GetPlayerType() == playerType then
|
||||
return true, player
|
||||
return true, player, i
|
||||
end
|
||||
if includeTainted and EID.isRepentance and EID.TaintedToRegularID[player:GetPlayerType()] == playerType then
|
||||
return true, player
|
||||
return true, player, i
|
||||
end
|
||||
end
|
||||
return false
|
||||
|
||||
@@ -19,12 +19,13 @@ Argument 4: Optional table that can define a variety of different settings
|
||||
-- General conditions
|
||||
-- Tarot Cloth (AB+ and Rep) (fallback to English because most are just find+replace)
|
||||
if not EID.isRepentance then
|
||||
EID:AddCollectibleConditional("5.300", 451, nil, {locTable = "tarotClothBuffsAB", replaceColor = "ColorShinyPurple", noFallback = false})
|
||||
else EID:AddCollectibleConditional("5.300", 451, nil, {locTable = "tarotClothBuffs", replaceColor = "ColorShinyPurple", noFallback = false}) end
|
||||
EID:AddCollectibleConditional("5.100", 356, EID.CheckForCarBattery, {locTable = "carBattery", replaceColor = "BlinkYellowGreen", noFallback = false}) -- Car Battery
|
||||
EID:AddItemConditional("5.300", 451, nil, {locTable = "tarotClothBuffsAB", replaceColor = "ColorShinyPurple", noFallback = false})
|
||||
else EID:AddItemConditional("5.300", 451, nil, {locTable = "tarotClothBuffs", replaceColor = "ColorShinyPurple", noFallback = false}) end
|
||||
EID:AddItemConditional("5.100", 356, EID.CheckForCarBattery, {locTable = "carBattery", replaceColor = "BlinkYellowGreen", noFallback = false}) -- Car Battery
|
||||
EID:AddItemConditional("5.100", 247, EID.CheckForBFFS, {locTable = "BFFSSynergies", replaceColor = "BlinkPink", noFallback = false}) -- BFFS!
|
||||
|
||||
-- IV Bag conditions (need to be applied in a specific order)
|
||||
EID:AddCollectibleConditional(135, 75, "PHD") -- PHD improves IV Bag
|
||||
EID:AddItemConditional(135, 75, "PHD") -- PHD improves IV Bag
|
||||
EID:AddPlayerConditional(135, 14, "Keeper 0-1") -- Keeper gets 0-1 coins
|
||||
if EID.isRepentance then EID:AddConditional(135, EID.IsHardMode, "Hard Mode") end -- Hard Mode pays out less
|
||||
|
||||
@@ -55,10 +56,13 @@ EID:AddPlayerConditional(501, 14) -- Keeper + Greed's Gullet
|
||||
EID:AddPlayerConditional(230, 14, "Keeper") -- Keeper + Abaddon
|
||||
|
||||
-- Item Synergies
|
||||
EID:AddSynergyConditional(7, 34) -- Martyr + Book of Belial/The Devil
|
||||
EID:AddCollectibleConditional("5.300.16", 7) -- Martyr + Book of Belial/The Devil
|
||||
EID:AddSynergyConditional(7, {34, "5.300.16"}) -- Martyr + Book of Belial/The Devil
|
||||
EID:AddSynergyConditional(316, 260) -- Black Candle + Cursed Eye
|
||||
EID:AddCollectibleConditional("5.300.48", 286, nil, { lineColor = "ColorSilver" }) -- Blank Card + ? Card
|
||||
EID:AddItemConditional("5.300.48", 286, nil, { lineColor = "ColorSilver" }) -- Blank Card + ? Card
|
||||
|
||||
EID:AddSynergyConditional({475, "5.300.46"}, {210}, "Suicide 1", "Suicide 2") -- Plan C + Gnawed Leaf
|
||||
EID:AddSynergyConditional({475, "5.300.46"}, {276, 313}, "Suicide 1", "Suicide 2") -- Plan C, Suicide King + Isaac's Heart, Holy Mantle
|
||||
EID:AddSynergyConditional(368, {69, 118, 316, 229, 395, 114, 329}, "Almost No Effect") -- Epiphora + Charge Shots / Ludovico
|
||||
|
||||
-- 9 Volt + 1 Room/Timed Charges
|
||||
-- This got a bit complicated, since it looks at a trait of every collectible + you having another, but hey, it's compact
|
||||
@@ -67,24 +71,37 @@ EID:AddConditional(116, function() return EID:CheckPlayersForActiveChargeType(ni
|
||||
EID:AddConditional("5.100", function(descObj) return EID:PlayersHaveCollectible(116) and EID:CheckActiveChargeType(descObj.ObjSubType, 1) end, "1 Room", { bulletpoint = "Collectible116" })
|
||||
EID:AddConditional("5.100", function(descObj) return EID:PlayersHaveCollectible(116) and EID:CheckActiveChargeType(descObj.ObjSubType, nil, 1) end, "Timed", { bulletpoint = "Collectible116" })
|
||||
|
||||
-- Overridden by Brimstone
|
||||
-- Items that have no effect from multiple copies (AddSelfConditional adds it when holding Diplopia automatically)
|
||||
-- 3 Dollar Bill,
|
||||
EID:AddSelfConditional({191}, "No Effect (Copies)")
|
||||
if not EID.isRepentance then
|
||||
-- Anti-Gravity,
|
||||
EID:AddSelfConditional({222}, "No Effect (Copies)")
|
||||
end
|
||||
if EID.isRepentance then
|
||||
-- 2Spooky,
|
||||
EID:AddSelfConditional({554}, "No Effect (Copies)")
|
||||
end
|
||||
|
||||
-- Overridden / Overrides by Epic Fetus, Brimstone, Mom's Knife
|
||||
-- Haven't done it yet but I'm sure preparing the system for it
|
||||
-- Remember most of these will be AB+ only (not EID.isRepentance)
|
||||
-- Remember some of these will be AB+ only (not EID.isRepentance)
|
||||
|
||||
-- AB+ only conditionals
|
||||
if not EID.isRepentance then
|
||||
EID:AddCollectibleConditional(205, {116, 276}, "No Effect") -- Sharp Plug + 9 Volt, Isaac's Heart
|
||||
EID:AddCollectibleConditional(205, 108, "Wafer") -- Sharp Plug + The Wafer
|
||||
EID:AddItemConditional(205, {116, 276}, "No Effect") -- Sharp Plug + 9 Volt, Isaac's Heart
|
||||
EID:AddItemConditional(205, 108, "Wafer") -- Sharp Plug + The Wafer
|
||||
EID:AddSynergyConditional(205, 441, "Can't Charge", "Can't Be Charged") -- Sharp Plug + Mega Blast
|
||||
|
||||
EID:AddConditional(208, function() return EID:IsHardMode() end) -- Champion Belt
|
||||
end
|
||||
|
||||
-- Rep only conditionals
|
||||
if EID.isRepentance then
|
||||
-- General conditions
|
||||
EID:AddCollectibleConditional("5.100", 706, nil, { locTable = "abyssSynergies", lineColor = "ColorRed" }, false) -- Abyss (no item reminder)
|
||||
EID:AddCollectibleConditional("5.100", 59, nil, { locTable = "bookOfBelialBuffs" }) -- Belial Birthright
|
||||
EID:AddCollectibleConditional("5.100", 664, nil, { locTable = "bingeEaterBuffs" }) -- Binge Eater
|
||||
EID:AddItemConditional("5.100", 706, nil, { locTable = "abyssSynergies", lineColor = "ColorRed" }, false) -- Abyss (no item reminder)
|
||||
EID:AddItemConditional("5.100", 59, nil, { locTable = "bookOfBelialBuffs" }) -- Belial Birthright
|
||||
EID:AddItemConditional("5.100", 664, nil, { locTable = "bingeEaterBuffs" }) -- Binge Eater
|
||||
|
||||
-- Co-op friendly items
|
||||
-- todo: which? (extension cord)
|
||||
@@ -107,6 +124,8 @@ if EID.isRepentance then
|
||||
EID:AddPlayerConditional(360, 13) -- Incubus + Lilith
|
||||
EID:AddPlayerConditional({ 240, 644 }, 21) -- Tainted Isaac + Experimental Treatment, Consolation Prize
|
||||
EID:AddPlayerConditional({ 642, 694 }, 10) -- Lost + Magic Skin, Heartbreak
|
||||
EID:AddPlayerConditional(694, 14, "Keeper", nil, false) -- Keeper + Heartbreak
|
||||
EID:AddPlayerConditional(694, 33, "Tainted Keeper") -- Tainted Keeper + Heartbreak
|
||||
EID:AddPlayerConditional("5.350.156", 14) -- Keeper + Mother's Kiss
|
||||
EID:AddPlayerConditional(230, 18, "Bethany", nil, false) -- Bethany + Abaddon
|
||||
EID:AddPlayerConditional(230, 36, "Tainted Bethany") -- Tainted Bethany + Abaddon
|
||||
@@ -115,15 +134,16 @@ if EID.isRepentance then
|
||||
EID:AddPlayerConditional(205, 22, "Tainted Magdalene")-- Tainted Magdalene + Sharp Plug
|
||||
|
||||
-- Item Synergies
|
||||
EID:AddCollectibleConditional(201, 147) -- Iron Bar refills Notched Axe
|
||||
EID:AddCollectibleConditional("5.350.172", 260) -- Black Candle + Cursed Penny
|
||||
EID:AddCollectibleConditional(501, 416) -- Greed's Gullet + Deep Pockets
|
||||
EID:AddItemConditional(201, 147) -- Iron Bar refills Notched Axe
|
||||
EID:AddItemConditional("5.350.172", 260) -- Black Candle + Cursed Penny
|
||||
EID:AddItemConditional(501, 416) -- Greed's Gullet + Deep Pockets
|
||||
EID:AddSynergyConditional(245, { 2, 153, 169 }, nil, "20/20") -- 20/20 + The Inner Eye, Mutant Spider, Polyphemus
|
||||
EID:AddSynergyConditional(330, 561, "Overridden", "Overrides") -- Soy Milk + Almond Milk
|
||||
|
||||
--TODO: SYNERGY CONDITIONAL DOESN'T WORK WITH TRINKETS YET, nothing I have works with trinkets yet really. need to detect trinket strings and handle them properly, and make a ConditionalTrinketCheck or something
|
||||
--EID:AddSynergyConditional(596, {"5.350.118", 704, 62, "5.350.60", 520, 411, 621, "5.350.58", "5.350.189", 657}, "Ice Tears") -- Uranus + On Kill Effects
|
||||
EID:AddSynergyConditional(596, {704, 62, 520, 411, 621, 657}, "Ice Tears") -- Uranus + On Kill Effects
|
||||
EID:AddSynergyConditional({577, 656}, {276, 313}, "Suicide 1", "Suicide 2") -- Damocles + Isaac's Heart, Holy Mantle
|
||||
EID:AddSynergyConditional({577, 656, 475, "5.300.46"}, {674, 694}, "Suicide 1", "Suicide 2") -- Damocles, Plan C, Suicide King + Spirit Shackles, Heartbreak
|
||||
|
||||
EID:AddSynergyConditional(596, {"5.350.118", 704, 62, "5.350.60", 520, 411, 621, "5.350.58", "5.350.189", 657}, "Ice Tears") -- Uranus + On Kill Effects
|
||||
EID:AddPlayerConditional(596, 27, "Ice Tears") -- Uranus + Tainted Samson
|
||||
|
||||
-- 9 Volt, Sharp Plug + Special Charge Actives
|
||||
|
||||
@@ -44,28 +44,41 @@ function EID:AddConditional(IDs, funcText, modText, extraTable, insertPoint)
|
||||
end
|
||||
end
|
||||
|
||||
-- Easy to use functions for conditionals that rely on having a specific collectible/character
|
||||
-- By default, they'll have a bulletpoint for the coll/char, and {1} becomes the coll/char's name
|
||||
-- Easy to use functions for conditionals that rely on having a specific item/character
|
||||
-- By default, they'll have a bulletpoint for the item/char, and {1} becomes the item/char's name
|
||||
|
||||
-- checkInReminder is for if a synergy is no longer relevant once the item isn't obtainable (e.g. Abyss locusts) (true by default)
|
||||
function EID:AddCollectibleConditional(IDs, ownedIDs, modText, extraTable, checkInReminder)
|
||||
function EID:AddItemConditional(IDs, ownedIDs, modText, extraTable, checkInReminder)
|
||||
if type(ownedIDs) ~= "table" then ownedIDs = { ownedIDs } end
|
||||
if checkInReminder == nil then checkInReminder = true end
|
||||
extraTable = extraTable or {}
|
||||
for _, ownedID in ipairs(ownedIDs) do
|
||||
EID.collectiblesToCheck[ownedID] = true
|
||||
local newTable = {}; for k, v in pairs(extraTable) do newTable[k] = v end
|
||||
if newTable.variableText == nil then newTable.variableText = "{{NameOnlyC" .. ownedID .. "}}" end
|
||||
if newTable.bulletpoint == nil then newTable.bulletpoint = "Collectible" .. ownedID end
|
||||
EID:AddConditional(IDs, function() return EID:ConditionalCollCheck(ownedID, checkInReminder) end, modText, newTable)
|
||||
local tvs = ownedID; if type(ownedID) == "number" then tvs = "5.100." .. ownedID end
|
||||
|
||||
if newTable.variableText == nil then newTable.variableText = "{{NameOnly" .. tvs .. "}}" end
|
||||
if newTable.bulletpoint == nil then newTable.bulletpoint = "Item" .. tvs end
|
||||
EID:AddConditional(IDs, function() return EID:ConditionalItemCheck(ownedID, checkInReminder) end, modText, newTable)
|
||||
end
|
||||
end
|
||||
|
||||
-- For adding pairs of abilities to collectibles; you can define a different modifier text for each of them
|
||||
-- example: EID:AddSynergyConditional({list of IDs overridden by Brimstone}, Brimstone, "Overridden", "Overrides")
|
||||
function EID:AddSynergyConditional(IDs, ownedIDs, modText1, modText2, extraTable1, extraTable2, checkInReminder)
|
||||
EID:AddCollectibleConditional(IDs, ownedIDs, modText1, extraTable1, checkInReminder)
|
||||
EID:AddCollectibleConditional(ownedIDs, IDs, modText2 or modText1, extraTable2 or extraTable1, checkInReminder)
|
||||
EID:AddItemConditional(IDs, ownedIDs, modText1, extraTable1, checkInReminder)
|
||||
EID:AddItemConditional(ownedIDs, IDs, modText2 or modText1, extraTable2 or extraTable1, checkInReminder)
|
||||
end
|
||||
|
||||
-- For adding a conditional that looks at owning itself; item reminder is of course disabled
|
||||
-- Holding Diplopia should probably also trigger this type of conditional, so it's included by default
|
||||
function EID:AddSelfConditional(ownedIDs, modText, extraTable, includeDiplopia)
|
||||
if type(ownedIDs) ~= "table" then ownedIDs = { ownedIDs } end
|
||||
if includeDiplopia == nil then includeDiplopia = true end
|
||||
for _, ownedID in ipairs(ownedIDs) do
|
||||
if includeDiplopia then EID:AddItemConditional(ownedID, {ownedID, 347}, modText, extraTable, false)
|
||||
else EID:AddItemConditional(ownedID, ownedID, modText, extraTable, false) end
|
||||
end
|
||||
end
|
||||
|
||||
-- includeTainted is for if you want to check the normal and tainted version of a character (true by default)
|
||||
@@ -84,47 +97,36 @@ end
|
||||
|
||||
----- Evaluation Functions -----
|
||||
|
||||
function EID:ConditionalItemCheck(itemID, checkInReminder)
|
||||
if EID.InsideItemReminder then
|
||||
if not checkInReminder then return false end
|
||||
local player = EID.ItemReminderPlayerEntity
|
||||
if EID:PlayerHasItem(player, itemID) or EID:PlayerVoidedCollectible(player, itemID) then return true end
|
||||
else
|
||||
return EID.collectiblesOwned[itemID] or EID.collectiblesAbsorbed[itemID]
|
||||
end
|
||||
end
|
||||
|
||||
function EID:ConditionalCharCheck(playerType, includeTainted)
|
||||
-- We don't want to display irrelevant item info inside the Item Reminder
|
||||
if EID.InsideItemReminder then
|
||||
local player = EID:ItemReminderGetAllPlayers()[EID.ItemReminderSelectedPlayer + 1] or EID.player
|
||||
local player = EID.ItemReminderPlayerEntity
|
||||
if player:GetPlayerType() == playerType then
|
||||
return true
|
||||
elseif includeTainted and EID.isRepentance and EID.TaintedToRegularID[player:GetPlayerType()] == playerType then
|
||||
return true
|
||||
else
|
||||
return false
|
||||
end
|
||||
else
|
||||
return EID:PlayersHaveCharacter(playerType, includeTainted)
|
||||
end
|
||||
end
|
||||
|
||||
function EID:ConditionalCollCheck(collectibleID, checkInReminder)
|
||||
-- We don't want to display irrelevant item info inside the Item Reminder
|
||||
if EID.InsideItemReminder then
|
||||
if not checkInReminder then return false end
|
||||
local player = EID:ItemReminderGetAllPlayers()[EID.ItemReminderSelectedPlayer + 1] or EID.player
|
||||
if player:HasCollectible(collectibleID) then return true end
|
||||
-- Check for the item being inside the Item Reminder player's Void (not sure if this is ever relevant...)
|
||||
if player:HasCollectible(477) then
|
||||
local playerID = EID:getPlayerID(player)
|
||||
if EID.absorbedItems[tostring(playerID)] and EID.absorbedItems[tostring(playerID)][tostring(collectibleID)] then
|
||||
return true
|
||||
end
|
||||
end
|
||||
else
|
||||
return EID.collectiblesOwned[collectibleID] or EID.collectiblesAbsorbed[collectibleID]
|
||||
end
|
||||
return false
|
||||
end
|
||||
|
||||
function EID:IsGreedMode()
|
||||
return game:IsGreedMode()
|
||||
end
|
||||
|
||||
function EID:IsGreedModePlusTarot()
|
||||
return game:IsGreedMode() and EID:ConditionalCollCheck(451, true)
|
||||
return game:IsGreedMode() and EID:ConditionalItemCheck(451, true)
|
||||
end
|
||||
|
||||
function EID:IsHardMode()
|
||||
@@ -156,6 +158,22 @@ function EID:CheckForCarBattery(descObj)
|
||||
else return descObj.ObjSubType end
|
||||
end
|
||||
|
||||
function EID:CheckForBFFS(descObj)
|
||||
local config = EID.itemConfig:GetCollectible(descObj.ObjSubType)
|
||||
-- Check for no effect, then the table of synergies (will we end up not doing the defualt "double damage" text?)
|
||||
if EID.BFFSNoSynergy[descObj.ObjSubType] then return "No Effect" end
|
||||
|
||||
if config ~= nil and config.Type == ItemType.ITEM_FAMILIAR then
|
||||
return descObj.fullItemString
|
||||
end
|
||||
return "N/A"
|
||||
end
|
||||
|
||||
function EID:CheckForHiveMind(descObj)
|
||||
if EID.HiveMindFamiliars[descObj.ObjSubType] then return descObj.fullItemString end
|
||||
return "N/A"
|
||||
end
|
||||
|
||||
-- Check for a player having an active item with a specific quantity of charges, or charge type
|
||||
-- 0 = normal, 1 = timed, 2 = special
|
||||
function EID:CheckPlayersForActiveChargeType(maxCharge, chargeType)
|
||||
@@ -236,7 +254,7 @@ function EID:applyConditionals(descObj)
|
||||
|
||||
local typeVar = descObj.ObjType.."."..descObj.ObjVariant -- for general conditions (Tarot Cloth, Book of Virtues)
|
||||
local typeVarSub = descObj.fullItemString -- for specific conditions
|
||||
-- Combine general+specific conditions into one table
|
||||
-- Combine specific+generic conditions into one table (in that order)
|
||||
local conds = {}
|
||||
if EID.DescriptionConditions[typeVarSub] then TableConcat(conds, EID.DescriptionConditions[typeVarSub]) end
|
||||
if EID.DescriptionConditions[typeVar] then TableConcat(conds, EID.DescriptionConditions[typeVar]) end
|
||||
@@ -286,24 +304,33 @@ function EID:applyConditionals(descObj)
|
||||
|
||||
-- Table with 2+ entries = find and replace pairs
|
||||
-- Entry 1 is replaced with entry 2, entry 3 is replaced with entry 4, etc.
|
||||
-- If there's an odd number of entries, the last one is appended
|
||||
else
|
||||
local pos = 1
|
||||
while pos < #text do
|
||||
local toFind = text[pos]
|
||||
local replaceWith = EID:ReplaceVariableStr(text[pos + 1], 1, variableText)
|
||||
if cond.replaceColor then replaceWith = "{{" .. cond.replaceColor .. "}}" .. replaceWith .. "{{CR}}" end
|
||||
--"%d*%.?%d+" will grab every number group (1, 10, 0.5), this will allow us to not replace the "1" in "10" erroneously
|
||||
if (type(toFind) == "number") then
|
||||
local count = 0
|
||||
descObj.Description = string.gsub(descObj.Description, "%d*%.?%d+", function(s)
|
||||
if (s == tostring(toFind) and count == 0) then
|
||||
count = count + 1
|
||||
return replaceWith
|
||||
end
|
||||
end)
|
||||
-- Basic find+replace for non-numbers
|
||||
if text[pos + 1] then
|
||||
local replaceWith = EID:ReplaceVariableStr(text[pos + 1], 1, variableText)
|
||||
if cond.replaceColor then replaceWith = "{{" .. cond.replaceColor .. "}}" .. replaceWith .. "{{CR}}" end
|
||||
--"%d*%.?%d+" will grab every number group (1, 10, 0.5), this will allow us to not replace the "1" in "10" erroneously
|
||||
if (type(toFind) == "number") then
|
||||
local count = 0
|
||||
descObj.Description = string.gsub(descObj.Description, "%d*%.?%d+", function(s)
|
||||
if (s == tostring(toFind) and count == 0) then
|
||||
count = count + 1
|
||||
return replaceWith
|
||||
end
|
||||
end)
|
||||
-- Basic find+replace for non-numbers
|
||||
else
|
||||
descObj.Description = replace(descObj.Description, tostring(toFind), replaceWith, 1)
|
||||
end
|
||||
else
|
||||
descObj.Description = replace(descObj.Description, tostring(toFind), replaceWith, 1)
|
||||
toFind = EID:ReplaceVariableStr(toFind, 1, variableText)
|
||||
local iconStr = "#"
|
||||
if bulletpoint then iconStr = iconStr .. "{{" .. bulletpoint .. "}} " end
|
||||
if cond.lineColor then iconStr = iconStr .. "{{" .. cond.lineColor .. "}}" end
|
||||
EID:appendToDescription(descObj, iconStr .. toFind:gsub("#", iconStr))
|
||||
end
|
||||
pos = pos + 2
|
||||
end
|
||||
|
||||
+18
-5
@@ -731,6 +731,11 @@ EID.InlineColors = {
|
||||
local c = EID.InlineColors
|
||||
return SwagColors({c["ColorYellow"], c["ColorRed"]})
|
||||
end,
|
||||
-- Pink for BFFs <3, the two shades come from Nancy Bombs and Eraser
|
||||
["BlinkPink"] = function(_)
|
||||
local c = EID.InlineColors
|
||||
return SwagColors({KColor(1, 0.698, 0.886, 1), KColor(1, 0.5, 1, 1)})
|
||||
end,
|
||||
-- Shiny purple color effect
|
||||
["ColorShinyPurple"] = function(_)
|
||||
return SwagColors({KColor(0.812, 0.627, 1, 1), KColor(0.62, 0.251, 1, 1)}, 40)
|
||||
@@ -940,17 +945,21 @@ if EID.isRepentance then
|
||||
end
|
||||
|
||||
-- Familiars that have no effect from BFFS!
|
||||
EID.BFFSNoSynergy = { [11] = true, [81] = true, [238] = true, [239] = true, [243] = true, [265] = true, [268] = true, [269] = true, [278] = true, [280] = true, [281] = true, [387] = true, [404] = true, [405] = true, [431] = true, [436] = true, [469] = true, [472] = true, [492] = true, [516] = true, [528] = true, [542] = true, [543] = true }
|
||||
-- todo: this table is wrong, for instance brown nugget didnt have one and then got one
|
||||
EID.BFFSNoSynergy = { [10] = true, [11] = true, [81] = true, [178] = true, [238] = true, [239] = true, [243] = true, [265] = true, [268] = true, [269] = true, [276] = true, [278] = true, [280] = true, [281] = true, [387] = true, [404] = true, [431] = true, [433] = true, [436] = true, [467] = true, [469] = true, [472] = true, [492] = true, [504] = true, [516] = true, [528] = true, [542] = true, [543] = true }
|
||||
if EID.isRepentance then
|
||||
EID.BFFSNoSynergy[504] = true -- Brown Nugget
|
||||
EID.BFFSNoSynergy[178] = false -- Holy Water
|
||||
EID.BFFSNoSynergy[276] = false -- Isaac's Heart
|
||||
EID.BFFSNoSynergy[405] = true -- GB Bug
|
||||
EID.BFFSNoSynergy[467] = false -- Finger!
|
||||
EID.BFFSNoSynergy[504] = false -- Brown Nugget
|
||||
EID.BFFSNoSynergy[567] = true -- Paschal Candle
|
||||
EID.BFFSNoSynergy[615] = true -- Lil Dumpy (I couldn't notice any change anyway)
|
||||
EID.BFFSNoSynergy[651] = true -- Star of Bethlehem
|
||||
EID.BFFSNoSynergy[697] = true -- Vanishing Twin
|
||||
end
|
||||
|
||||
-- Familiars that have a BFFS! effect from Hive Mind
|
||||
EID.HiveMindFamiliars = {}
|
||||
-- Familiars that count for Hive Mind in Repentance (although it could give them No Effect if it just increases size)
|
||||
EID.HiveMindFamiliars = { [10] = true, [57] = true, [128] = true, [170] = true, [264] = true, [272] = true, [274] = true, [279] = true, [320] = true, [364] = true, [365] = true, [403] = true, [426] = true, [430] = true, [504] = true, [511] = true, [575] = true, [581] = true, [629] = true, }
|
||||
|
||||
-- Tainted character's respective normal version ID, for conditionals that apply to both versions of the character
|
||||
-- To help with other character pairs, Esau = Jacob, Dead Tainted Lazarus = Tainted Lazarus, Tainted Soul = Tainted Forgotten
|
||||
@@ -971,6 +980,10 @@ EID.blankCardHidden = {[32]=true,[33]=true,[34]=true,[35]=true,[36]=true,[37]=tr
|
||||
-- Cards that are treated as runes
|
||||
EID.runeIDs = {[32]=true,[33]=true,[34]=true,[35]=true,[36]=true,[37]=true,[38]=true,[39]=true,[40]=true,[41]=true,[55]=true,[81]=true,[82]=true,[83]=true,[84]=true,[85]=true,[86]=true,[87]=true,[88]=true,[89]=true,[90]=true,[91]=true,[92]=true,[93]=true,[94]=true,[95]=true,[96]=true,[97]=true,}
|
||||
|
||||
-- "Evil" item IDs for Black Feather
|
||||
EID.blackFeatherItems = {[215]=true,[216]=true,[230]=true,[260]=true,[262]=true,[339]=true,[344]=true}
|
||||
if EID.isRepentance then EID.blackFeatherItems[654] = true end
|
||||
EID.blackFeatherTrinkets = {[17]=true,[22]=true}
|
||||
|
||||
|
||||
---------------- BAG OF CRAFTING DATA ------------------
|
||||
|
||||
@@ -12,6 +12,7 @@ EID.ItemReminderSelectedCategory = 0 -- Currently selected category
|
||||
EID.ItemReminderSelectedPlayer = 0 -- Currently selected player
|
||||
EID.ItemReminderSelectedItem = 0 -- Currently selected Item
|
||||
EID.InsideItemReminder = false -- Disable some modifiers, when building the Item Reminder description
|
||||
EID.ItemReminderPlayerEntity = nil -- for description modifiers to reference
|
||||
|
||||
-- TODO:
|
||||
-- crooked penny cheats. 404/liberty cap/broken syringe/etc. "what item is it"
|
||||
@@ -72,7 +73,6 @@ EID.ItemReminderDescriptionModifier = {
|
||||
---------------- Passive Items ----------------
|
||||
["5.100.392"] = { -- Zodiac
|
||||
isHiddenInfo = true,
|
||||
isRepentance = true,
|
||||
modifierFunction = function(descObj, player)
|
||||
local zodiacItem = player:GetZodiacEffect()
|
||||
if zodiacItem > 0 then
|
||||
@@ -121,11 +121,10 @@ EID.ItemReminderDescriptionModifier = {
|
||||
|
||||
["5.100.44"] = { -- Teleport! location
|
||||
isCheat = true,
|
||||
isRepentance = true,
|
||||
-- The result preview changes as soon as we activate Teleport, which looks awkward, so try to not display the result while mid-teleport.
|
||||
-- Doesn't work perfectly and only in Rep
|
||||
modifierFunction = function(descObj, player)
|
||||
if player:GetSprite():GetAnimation() ~= "TeleportUp" then
|
||||
-- The result preview changes as soon as we activate Teleport, which looks awkward, so try to not display the result while mid-teleport.
|
||||
-- Doesn't work perfectly and only in Rep
|
||||
if not EID.isRepentance or player:GetSprite():GetAnimation() ~= "TeleportUp" then
|
||||
EID:ItemReminderAddResultHeaderSuffix(descObj)
|
||||
descObj.Description = EID:Teleport1Prediction(EID:GetItemSeed(player, 44))
|
||||
end
|
||||
@@ -310,10 +309,12 @@ function EID:ItemReminderAddDescription(player, entityType, variant, subType, ex
|
||||
|
||||
local specialDesc = EID.ItemReminderDescriptionModifier[objectID]
|
||||
if specialDesc and type(specialDesc.modifierFunction) == "function" then
|
||||
-- dont add, if description modifier is a cheat and cheats are disabled
|
||||
local evalShowCheat = not (specialDesc.isCheat and not EID.Config["ItemReminderShowRNGCheats"])
|
||||
local evalShowHidden = not (specialDesc.isHidden and not EID.Config["ItemReminderShowHiddenInfo"])
|
||||
if evalShowCheat or evalShowHidden then
|
||||
-- don't add, if description modifier is a cheat and cheats are disabled
|
||||
local evaluateFunction = true
|
||||
if (specialDesc.isCheat and not EID.Config["ItemReminderShowRNGCheats"]) then evaluateFunction = false end
|
||||
if (specialDesc.isHiddenInfo and not EID.Config["ItemReminderShowHiddenInfo"]) then evaluateFunction = false end
|
||||
if (specialDesc.isRepentance and not EID.isRepentance) then evaluateFunction = false end
|
||||
if evaluateFunction then
|
||||
specialDesc.modifierFunction(descObj, player)
|
||||
end
|
||||
end
|
||||
@@ -598,6 +599,7 @@ function EID:ItemReminderGetDescription()
|
||||
for key, _ in pairs(EID.ItemReminderBlacklist) do currentBlacklist[key] = true end
|
||||
|
||||
local player = EID:ItemReminderGetAllPlayers()[EID.ItemReminderSelectedPlayer + 1] or EID.player -- use main player as fallback
|
||||
EID.ItemReminderPlayerEntity = player -- for description modifiers to reference
|
||||
|
||||
if EID.ItemReminderSelectedCategory == 0 or EID.Config["ItemReminderDisplayMode"] == "Classic" then
|
||||
-- execute all functions defined per category
|
||||
|
||||
+19
-53
@@ -3,12 +3,12 @@ local game = Game()
|
||||
EID.TabPreviewID = 0
|
||||
-- Modifiers switching the previewed description can cause infinite loops or undesired text, use this to help prevent it
|
||||
EID.inModifierPreview = false
|
||||
-- The "Hold Map Helper" needs to know if it shouldn't display because we're in a Hold Tab desc
|
||||
-- The "Item Reminder" needs to know if it shouldn't display because we're in a Hold Tab desc
|
||||
EID.TabDescThisFrame = false
|
||||
|
||||
-- List of collectible IDs for us to check if a player owns them; feel free to add to this in mods that add description modifiers!
|
||||
EID.collectiblesToCheck[CollectibleType.COLLECTIBLE_VOID] = true
|
||||
EID.collectiblesToCheck[CollectibleType.COLLECTIBLE_BFFS] = true
|
||||
EID.collectiblesToCheck["5.300.41"] = true -- Black Rune
|
||||
local maxSlot = 1
|
||||
-- Repentance modifiers
|
||||
if EID.isRepentance then
|
||||
@@ -25,9 +25,6 @@ if EID.isRepentance then
|
||||
end
|
||||
EID.collectiblesOwned = {}
|
||||
EID.collectiblesAbsorbed = {}
|
||||
EID.blackRuneOwned = false
|
||||
EID.blackFeatherItems = {[215]=true,[216]=true,[230]=true,[260]=true,[262]=true,[339]=true,[344]=true,[654]=true,}
|
||||
EID.blackFeatherTrinkets = {[17]=true,[22]=true}
|
||||
|
||||
EID.LastCollectibleCheck = 0
|
||||
function EID:CheckPlayersCollectibles()
|
||||
@@ -35,30 +32,17 @@ function EID:CheckPlayersCollectibles()
|
||||
-- (has to be checked regularly due to mechanics like D4 / Tainted Eden)
|
||||
if EID.GameUpdateCount >= EID.LastCollectibleCheck + 15 then
|
||||
EID.LastCollectibleCheck = EID.GameUpdateCount
|
||||
local numPlayers = game:GetNumPlayers()
|
||||
local players = {}; for i = 0, numPlayers - 1 do players[i] = Isaac.GetPlayer(i) end
|
||||
for v,_ in pairs(EID.collectiblesToCheck) do
|
||||
EID.collectiblesOwned[v] = false
|
||||
EID.collectiblesAbsorbed[v] = false
|
||||
for i = 0, numPlayers - 1 do
|
||||
if players[i]:HasCollectible(v) then
|
||||
EID.collectiblesOwned[v] = i
|
||||
break
|
||||
-- Check for the item being inside this player's Void
|
||||
-- note: currently Absorb checks are only done as a backup, will always be false if it's owned legitimately
|
||||
elseif EID.absorbedItems[tostring(i)] and EID.absorbedItems[tostring(i)][tostring(v)] and players[i]:HasCollectible(477) then
|
||||
EID.collectiblesAbsorbed[v] = i
|
||||
end
|
||||
end
|
||||
end
|
||||
-- other Card in inventory checks could be done in this loop here if ever desired
|
||||
EID.blackRuneOwned = false
|
||||
for i = 0, numPlayers - 1 do
|
||||
for j = 0, maxSlot do
|
||||
if players[i]:GetCard(j) == Card.RUNE_BLACK then
|
||||
EID.blackRuneOwned = i
|
||||
break
|
||||
end
|
||||
-- Check for any player having the item, set collectiblesOwned to that player's ID
|
||||
local result, player, playerNum = EID:PlayersHaveItem(v)
|
||||
if result then EID.collectiblesOwned[v] = playerNum
|
||||
-- Check for the item being inside a player's Void if it's a collectible
|
||||
-- note: currently Absorb checks are only done as a backup, will always be false if it's owned legitimately
|
||||
elseif type(v) == "number" then
|
||||
result, player, playerNum = EID:PlayersVoidedCollectible(v)
|
||||
if result then EID.collectiblesAbsorbed[v] = playerNum end
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -93,7 +77,7 @@ local function VoidCallback(descObj, isRune)
|
||||
if EID.GameUpdateCount >= lastVoidCheck + 30 or EID.RecheckVoid then
|
||||
EID:VoidRoomCheck()
|
||||
if EID.collectiblesOwned[477] then EID:VoidRNGCheck(Isaac.GetPlayer(EID.collectiblesOwned[477]), false) end
|
||||
if EID.blackRuneOwned then EID:VoidRNGCheck(Isaac.GetPlayer(EID.blackRuneOwned), true) end
|
||||
if EID.collectiblesOwned["5.300.41"] then EID:VoidRNGCheck(Isaac.GetPlayer(EID.collectiblesOwned["5.300.41"]), true) end
|
||||
lastVoidCheck = EID.GameUpdateCount
|
||||
EID.RecheckVoid = false
|
||||
end
|
||||
@@ -229,24 +213,25 @@ local function SacrificeRoomCallback(descObj)
|
||||
return descObj
|
||||
end
|
||||
|
||||
-- Handle Black Feather dynamic damage up text
|
||||
-- TODO: Make this co-op friendly, add conditionals to the black feather items
|
||||
local function BlackFeatherCallback(descObj)
|
||||
local itemCounter = 0
|
||||
for itemID, _ in pairs(EID.blackFeatherItems) do
|
||||
itemCounter = itemCounter + EID.player:GetCollectibleNum(itemID)
|
||||
end
|
||||
for trinketID, _ in pairs(EID.blackFeatherTrinkets) do
|
||||
-- in AB+, GetTrinketMultiplier doesn't take an ID, it's just 1 (or 2 with Mom's Box)
|
||||
if EID.isRepentance then
|
||||
itemCounter = itemCounter + EID.player:GetTrinketMultiplier(trinketID)
|
||||
else
|
||||
if EID.player:GetTrinket(0) == trinketID then itemCounter = itemCounter + EID.player:GetTrinketMultiplier() end
|
||||
if EID.player:GetTrinket(1) == trinketID then itemCounter = itemCounter + EID.player:GetTrinketMultiplier() end
|
||||
if EID.player:HasTrinket(trinketID) then itemCounter = itemCounter + 1 end
|
||||
end
|
||||
end
|
||||
|
||||
local hasBox = EID.collectiblesOwned[439]
|
||||
local hasBox = EID.player:HasCollectible(439)
|
||||
local isGolden = EID.isRepentance and ((descObj.ObjSubType & TrinketType.TRINKET_GOLDEN_FLAG) == TrinketType.TRINKET_GOLDEN_FLAG)
|
||||
local damageMultiplied = 0.5 * itemCounter * (hasBox and 2 or 1) * (isGolden and 2 or 1)
|
||||
local base = EID.isRepentance and 0.5 or 0.2
|
||||
local damageMultiplied = base * itemCounter * (hasBox and 2 or 1) * (isGolden and 2 or 1)
|
||||
local dmgColor = (hasBox or isGolden) and "ColorGold" or "ColorLime"
|
||||
|
||||
local description = EID:getDescriptionEntry("BlackFeatherInformation")
|
||||
@@ -257,18 +242,6 @@ local function BlackFeatherCallback(descObj)
|
||||
return descObj
|
||||
end
|
||||
|
||||
local function BFFSSynergiesCallback(descObj)
|
||||
local description = EID:getDescriptionEntry("BFFSSynergies", descObj.fullItemString, true)
|
||||
if EID.BFFSNoSynergy[descObj.ObjSubType] then
|
||||
description = EID:getDescriptionEntry("BFFSSynergies", "NoEffect")
|
||||
elseif description == nil then
|
||||
description = EID:getDescriptionEntry("BFFSSynergies", "DoubleDamage")
|
||||
end
|
||||
|
||||
EID:appendToDescription(descObj, "#{{Collectible247}} {{ColorOrange}}" .. description .. "{{CR}}")
|
||||
return descObj
|
||||
end
|
||||
|
||||
if EID.isRepentance then
|
||||
-- Handle Birthright
|
||||
local function BirthrightCallback(descObj)
|
||||
@@ -804,16 +777,9 @@ local function EIDConditionsAB(descObj)
|
||||
|
||||
if EID.Config["DisplayVoidStatInfo"] then
|
||||
if EID.collectiblesOwned[477] then table.insert(callbacks, VoidCallback) end
|
||||
if EID.blackRuneOwned then table.insert(callbacks, BlackRuneCallback) end
|
||||
end
|
||||
|
||||
-- BFF Synergy check
|
||||
if EID.collectiblesOwned[247] then
|
||||
local config = EID.itemConfig:GetCollectible(descObj.ObjSubType)
|
||||
if config ~= nil and config.Type == ItemType.ITEM_FAMILIAR then
|
||||
table.insert(callbacks, BFFSSynergiesCallback)
|
||||
end
|
||||
if EID.collectiblesOwned["5.300.41"] then table.insert(callbacks, BlackRuneCallback) end
|
||||
end
|
||||
|
||||
elseif descObj.ObjVariant == PickupVariant.PICKUP_TRINKET then
|
||||
if descObj.ObjSubType == 80 then table.insert(callbacks, BlackFeatherCallback) end
|
||||
end
|
||||
|
||||
Reference in new issue
Block a user