4,951
edits
Falterfire (talk | contribs) (Added unified 'getItemSources' function) |
Falterfire (talk | contribs) (Changed duplicate function name) |
||
Line 991: | Line 991: | ||
end | end | ||
function p. | function p._getItemSourceTables(item) | ||
local result = '' | local result = '' | ||
local creationTable = p._getCreationTable(item) | local creationTable = p._getCreationTable(item) | ||
Line 997: | Line 997: | ||
local lootTable = p._getItemLootSourceTable(item) | local lootTable = p._getItemLootSourceTable(item) | ||
if string.len(lootTable) > 0 then | if string.len(lootTable) > 0 then | ||
if string.len(result) > 0 then result = result..'<br/>' end | if string.len(result) > 0 then result = result..'<br/>\r\n' end | ||
result = result..lootTable | result = result..lootTable | ||
end | end | ||
Line 1,003: | Line 1,003: | ||
end | end | ||
function p. | function p.getItemSourceTables(frame) | ||
local itemName = frame.args ~= nil and frame.args[1] or frame | local itemName = frame.args ~= nil and frame.args[1] or frame | ||
local item = p.getItem(itemName) | local item = p.getItem(itemName) | ||
Line 1,010: | Line 1,010: | ||
end | end | ||
return p. | return p._getItemSourceTables(item) | ||
end | end | ||