17,101
edits
(_buildAstrologyConstellationTable: Amend for new modifier format; buildAstrologyValueTable: Remove as now redundant following skill rework) |
(getToolTable: Add variable header support for each tool type) |
||
Line 13: | Line 13: | ||
-- TODO Move tool tables to Module:Shop | -- TODO Move tool tables to Module:Shop | ||
function p.getToolTable(searchString, modifiers, skillID) | function p.getToolTable(toolName, searchString, modifiers, skillID) | ||
local skillName = Constants.getSkillName(skillID) | local skillName = Constants.getSkillName(skillID) | ||
local toolArray = Shop.getPurchases( | local toolArray = Shop.getPurchases( | ||
Line 43: | Line 43: | ||
end | end | ||
if headerRowSpan > 1 then | if headerRowSpan > 1 then | ||
table.insert(resultPart, '\r\n|-' .. string.rep('\r\n!This | table.insert(resultPart, '\r\n|-' .. string.rep('\r\n!This ' .. toolName .. '\r\n!Total', Shared.tableCount(modifiers))) | ||
end | end | ||
Line 96: | Line 96: | ||
} | } | ||
return p.getToolTable('_Axe$', modifiers, 'melvorD:Woodcutting') | return p.getToolTable('Axe', '_Axe$', modifiers, 'melvorD:Woodcutting') | ||
end | end | ||
Line 108: | Line 108: | ||
} | } | ||
return p.getToolTable('_Pickaxe$', modifiers, 'melvorD:Mining') | return p.getToolTable('Pickaxe', '_Pickaxe$', modifiers, 'melvorD:Mining') | ||
end | end | ||
Line 119: | Line 119: | ||
} | } | ||
return p.getToolTable('_Rod$', modifiers, 'melvorD:Fishing') | return p.getToolTable('Rod', '_Rod$', modifiers, 'melvorD:Fishing') | ||
end | end | ||