Fix Card Reading + Blank Card

This commit is contained in:
Buurazu authored and GitHub committed 2022-03-13 01:47:03 -05:00
1 parent a0bc4400a6
commit 4559c284dc
1 file changed
+3 -1
+3 -1
View File
@@ -337,7 +337,7 @@ end
-- returns the description object of the specified entity -- returns the description object of the specified entity
-- falls back to english if the objID isnt available -- falls back to english if the objID isnt available
-- entity is optional -- entity is optional
function EID:getDescriptionObj(Type, Variant, SubType, entity) function EID:getDescriptionObj(Type, Variant, SubType, entity, checkModifiers)
local description = {} local description = {}
description.ObjType = Type description.ObjType = Type
description.ObjVariant = Variant description.ObjVariant = Variant
@@ -353,6 +353,7 @@ function EID:getDescriptionObj(Type, Variant, SubType, entity)
description.ModName = tableEntry and tableEntry[4] description.ModName = tableEntry and tableEntry[4]
if checkModifiers ~= false then
for _,modifier in ipairs(EID.DescModifiers) do for _,modifier in ipairs(EID.DescModifiers) do
local result = modifier.condition(description) local result = modifier.condition(description)
if type(result) == "table" then if type(result) == "table" then
@@ -365,6 +366,7 @@ function EID:getDescriptionObj(Type, Variant, SubType, entity)
description = modifier.callback(description) description = modifier.callback(description)
end end
end end
end
return description return description
end end