Module:ItemTables: Difference between revisions

Jump to navigation Jump to search
catch 0m,
Undo revision 12069 by Sylphoid (talk) move up catch
Line 13: Line 13:
for _, v in pairs(data) do
for _, v in pairs(data) do
for _, value in ipairs(property) do
for _, value in ipairs(property) do
if (v[value] ~= nil and v["Disabled"] == false and v["Name"] ~= nil and v[value] ~= "0" ) then
if (v[value] ~= nil and v["Disabled"] == false and v["Name"] ~= nil and v[value] ~= "0" and v[value] ~= "0m") then
table.insert(similarItems, v)
table.insert(similarItems, v)
end
end
Line 200: Line 200:
for k, t in pairs(listofKeysTable) do
for k, t in pairs(listofKeysTable) do
-- filter out items that: don't have the property and the value isn't zero
-- filter out items that: don't have the property and the value isn't zero
if(itemName[t] ~= nil and itemName[t] ~= "0" and itemName[t] ~= "0m" ) then
if(itemName[t] ~= nil and itemName[t] ~= "0" ) then
listofItems = listofItems .. itemName["Name"] .. "<br/>"
listofItems = listofItems .. itemName["Name"] .. "<br/>"
copyVar = copyVar:gsub("^%l", string.upper)
copyVar = copyVar:gsub("^%l", string.upper)