Module:TFTUnitData

-- local p   = {} local lib      = require('Module:Feature') local userError = require('Dev:User error')

function p.get(frame) local args; if frame.args == nil then args = lib.arguments(frame) else args = lib.arguments(frame.args) end local get      = require ('Module:TFTUnitData/getter') local champname = args['champname'] or args[1] local set      = args['set']       or args[2] or false local data     = args['data']      or args[3] return get[data](champname, set) end

function p.getRoster(frame) local args; if frame.args == nil then args = lib.arguments(frame) else args = lib.arguments(frame.args) end local data     = require('Module:TFTUnitData/data') local set      = args[1] or 2 local roster --do for every champion --IF SET --roster = roster & for champion in pairs (data) do       for set in pairs (champion) do            if champion.set == set then roster = roster .. ""           end end end return roster end

function p.getGroup(frame) local args; if frame.args == nil then args = lib.arguments(frame) else args = lib.arguments(frame.args) end local get      = require ('Module:TFTUnitData/getter') local set      = args['set']       or args[1] or false local synergy  = args['syngery']   or args[2] local data     = args['data']      or args[3] local roster --do for every champion --if SET --if SYNERGY --roster = roster & --this could be combined with the above if you automatically return all if no synergy is mentioned return roster end

return p -- --