Anonymous

Module:Common: Difference between revisions

From Melvor Idle
No change in size ,  9 September 2023
m
Fix function name typo
(New module, attempting to avoid module requirement loops when modules which require many modules also have functions which are desired by other modules)
 
m (Fix function name typo)
Line 141: Line 141:
end
end
elseif req.type == 'ItemFound' then
elseif req.type == 'ItemFound' then
local item = GameData.getObjectByID('items', req.itemID)
local item = GameData.getEntityByID('items', req.itemID)
if item ~= nil then
if item ~= nil then
table.insert(reqArray, 'Find ' .. Icons.Icon({item.name, type='item'}))
table.insert(reqArray, 'Find ' .. Icons.Icon({item.name, type='item'}))