diff --git a/features/eid_api.lua b/features/eid_api.lua index 1b268c9f..5d252d43 100644 --- a/features/eid_api.lua +++ b/features/eid_api.lua @@ -636,14 +636,17 @@ function EID:getObjectName(Type, Variant, SubType) if tableName == "collectibles" then if EID.itemConfig:GetCollectible(SubType) == nil then return Type.."."..Variant.."."..SubType end local vanillaName = EID.itemConfig:GetCollectible(SubType).Name - return name or (not string.find(vanillaName, "^#") and vanillaName) or (EID.descriptions["en_us"][tableName][SubType] and EID.descriptions["en_us"][tableName][SubType][2]) or vanillaName + local englishName = EID.descriptions["en_us"][tableName][SubType] and EID.descriptions["en_us"][tableName][SubType][2] + return name or (not string.find(vanillaName, "^#") and vanillaName) or englishName or vanillaName elseif tableName == "trinkets" then local adjustedSubtype = EID:getAdjustedSubtype(Type, Variant, SubType) local vanillaName = EID.itemConfig:GetTrinket(adjustedSubtype).Name - return name or (not string.find(vanillaName, "^#") and vanillaName) or EID.descriptions["en_us"][tableName][adjustedSubtype][2] or vanillaName + local englishName = EID.descriptions["en_us"][tableName][adjustedSubtype] and EID.descriptions["en_us"][tableName][adjustedSubtype][2] + return name or (not string.find(vanillaName, "^#") and vanillaName) or englishName or vanillaName elseif tableName == "cards" then 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 + local englishName = EID.descriptions["en_us"][tableName][SubType] and EID.descriptions["en_us"][tableName][SubType][2] + return name or (not string.find(vanillaName, "^#") and vanillaName) or englishName or vanillaName elseif tableName == "pills" or tableName == "horsepills" then local adjustedSubtype = EID:getAdjustedSubtype(Type, Variant, SubType) return EID:getPillName(adjustedSubtype, tableName == "horsepills")