From Feed The Beast Wiki
Revision as of 22:38, 20 August 2015 by Xbony2 (talk | contribs) (added minor optimization :P)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Documentation for this module may be created at Module:PrimalAspect/doc

local p = {}

function toGrid(aspect, size)
	return mw.getCurrentFrame():expandTemplate{title = "G/Cell", args = {aspect, size, mod = "TC4A", link = "none"}}

function p.aspect(params)
	local aspect = params.args.aspect
	local size = params.args.stacksize -- defaults to 1 via the template
	if aspect == "A" then
		return toGrid("Aer", size)
	elseif aspect == "T" then
		return toGrid("Terra", size)
	elseif aspect == "I" then
		return toGrid("Ignis", size)
	elseif aspect == "Aq" or aspect == "Q" then
		return toGrid("Aqua", size)
	elseif aspect == "O" then
		return toGrid("Ordo", size)
	elseif aspect == "P" then
		return toGrid("Perditio", size)
   		return toGrid(aspect, size)

return p