Module:Pokemon/Trainer

local p = {} function p.mon( frame ) local game = frame:getParent.args[1] or 'red' local monNum = frame:getParent.args[2] or '001' local gender = frame:getParent.args[3] or 'M'	local level = frame:getParent.args[4] or '?' local item = frame:getParent.args[5] or '' local shadow = frame:getParent.args[6] or ''

local pokedex = mw.loadJsonData( 'Module:Pokemon/Pokedex.json' )

if tonumber(monNum) >= 100 then monNum = tonumber(monNum) end local monName = pokedex[monNum] local entry = { ' ', 		monName, ' Lv.', level }	local item = mw.html.create('li'):wikitext(table.concat(entry))

return tostring(item) end

return p