Module:Recipe: Difference between revisions

no edit summary
No edit summary
No edit summary
 
(4 intermediate revisions by the same user not shown)
Line 90:
function p.main(frame)
local args = frame:getParent().args
local category = args.category or ''
 
local function cost_to_number(cost_v, name, currencyName)
Line 212 ⟶ 213:
local xp = v.experience == '?' and edit or v.experience
 
local citeTextframe = frame:expandTemplate{mw.getCurrentFrame()
local citeText = frame:expandTemplate{
title = 'CiteText',
args title = {'CiteText',
textargs = 'Experience boost',{
text = 'Experience boost',
quote = 'The experience shown is for players on the normal gamemode, without any other [[experience boosts]] active.'
}
}
}
}
 
requirement = mw.html.create('tr')
requirement
Line 577 ⟶ 579:
-- Because string values are expected by smw, we convert the boolean values back to strings here
members = members and 'Yes' or members == false and 'No' or ''
local jsonObject = {skills = skills, members = members, materials = {}, output = output[1], ticks = ticks, facilities = facilities, tools = tools, category = args.category }
local materialNames = {}
for _, v in ipairs(materials) do
Line 588 ⟶ 590:
['Uses facility'] = mw.text.split(facilities or '', '%s*,%s*'),
['Is members only'] = members,
['RecipeCategory'] = args.category,
['Production JSON'] = mw.text.jsonEncode(jsonObject),
['Is boostable'] = {},