17,101
edits
(Fix call to _getItemSources) |
(_buildAstrologyConstellationTable: Amend for new modifier format; buildAstrologyValueTable: Remove as now redundant following skill rework) |
||
Line 714: | Line 714: | ||
function p._buildAstrologyConstellationTable() | function p._buildAstrologyConstellationTable() | ||
local result = '{|class="wikitable sortable stickyHeader"' | local result = '{|class="wikitable sortable stickyHeader"' | ||
result = result..'\r\n|- class="headerRow-0"' | result = result..'\r\n|- class="headerRow-0"' | ||
Line 720: | Line 719: | ||
result = result..'!!XP!!Skills!!Standard Modifiers!!Unique Modifiers' | result = result..'!!XP!!Skills!!Standard Modifiers!!Unique Modifiers' | ||
for i, cons in ipairs(SkillData.Astrology. | for i, cons in ipairs(SkillData.Astrology.recipes) do | ||
local name = cons.name | local name = cons.name | ||
result = result..'\r\n|-' | result = result..'\r\n|-' | ||
result = result..'\r\n|data-sort-value="'..name..'"|'..Icons.Icon({name, type='constellation', size='50', notext=true})..'||'..name | result = result..'\r\n|data-sort-value="'..name..'"|'..Icons.Icon({name, type='constellation', size='50', notext=true})..'||'..name | ||
result = result..'||'..cons.level..'||'..cons. | result = result..'||'..cons.level..'||'..cons.baseExperience | ||
local skillIconArray = {} | local skillIconArray = {} | ||
for j, skillID in ipairs(cons. | for j, skillID in ipairs(cons.skillIDs) do | ||
table.insert(skillIconArray, Icons.Icon({Constants.getSkillName(skillID), type='skill'})) | table.insert(skillIconArray, Icons.Icon({Constants.getSkillName(skillID), type='skill'})) | ||
end | end | ||
result = result..'||'..table.concat(skillIconArray, '<br/>') | result = result..'||'..table.concat(skillIconArray, '<br/>') | ||
local standModsRaw = Skills._buildAstrologyModifierArray(cons, | local standModsRaw = Skills._buildAstrologyModifierArray(cons, nil, true, false, false, false) | ||
local standMods = {} | local standMods = {} | ||
--Building the list of Standard modifiers: | --Building the list of Standard modifiers: | ||
for j, modifier in ipairs(standModsRaw) do | for j, modifier in ipairs(standModsRaw) do | ||
table.insert(standMods, Constants._getModifierText(modifier[1], | local modMagnitude = type(modifier[2]) == 'table' and {modifier[2]} or modifier[2] | ||
table.insert(standMods, Constants._getModifierText(modifier[1], modMagnitude, false)) | |||
end | end | ||
result = result..'|| '..table.concat(standMods, '<br/>') | result = result..'|| '..table.concat(standMods, '<br/>') | ||
--Building the list of all Unique Modifiers | --Building the list of all Unique Modifiers | ||
local uModsRaw = Skills._buildAstrologyModifierArray(cons, | local uModsRaw = Skills._buildAstrologyModifierArray(cons, nil, false, true, false, false) | ||
local uMods = {} | local uMods = {} | ||
for j, modifier in ipairs(uModsRaw) do | for j, modifier in ipairs(uModsRaw) do | ||
table.insert(uMods, Constants._getModifierText(modifier[1], | local modMagnitude = type(modifier[2]) == 'table' and {modifier[2]} or modifier[2] | ||
table.insert(uMods, Constants._getModifierText(modifier[1], modMagnitude, false)) | |||
end | end | ||
result = result..'||'..table.concat(uMods, '<br/>') | result = result..'||'..table.concat(uMods, '<br/>') | ||
Line 755: | Line 756: | ||
function p.buildAstrologyConstellationTable(frame) | function p.buildAstrologyConstellationTable(frame) | ||
return p._buildAstrologyConstellationTable() | return p._buildAstrologyConstellationTable() | ||
end | end | ||
return p | return p |