Module:ProfessionList: Difference between revisions

m
profit per xp
No edit summary
m (profit per xp)
(3 intermediate revisions by the same user not shown)
Line 155:
-- include the price of selling the product
item.sellPrice = search.getShopSellPrice(item.product)
item.profit = item.buyPrice and item.sellPrice and item.sellPrice - item.buyPrice
item.profitPerXP = item.profit and item.xp and item.profit / item.xp
end
return output
end
 
function p.one_column_image_text(sort,materials)
local materialCell = mw.html.create('td')
 
for _, mat in ipairs(item.materials) do
materialCell:wikitext(mat.quantity .. ' &times; [[File:' .. mat.name .. '.png|18px|link=' .. mat.name .. ']] [[' .. mat.name .. ']]<br>')
end
return materialCell
end
Line 186 ⟶ 201:
:addClass('plinkt-image no-border')
:css{ ['border-left'] = '0', ['padding-left'] = '0' }
:wikitext('[[File:' .. image .. '.png|link=' .. link .. '|30px]]')
:done()
:tag('td')
11,305

edits