Module:NPCPriceSpread

local getArgs = require('Module:Arguments').getArgs

local p = {} local table = require('Module:Table') local string = require('Module:String')

function p.main(frame) args = getArgs(frame) return mw.getCurrentFrame:preprocess(p.writeText(args)) end

function p.writeText(args) local text = {} local values = {args["coins"] * 0.97,args["coins"] * 0.98,args["coins"] * 0.99,args["coins"],args["coins"] * 1.07,args["coins"] * 1.08,args["coins"] * 1.09,args["coins"] * 1.1} if args["ending"] == nil then ending = 'possible' else ending = args["ending"] end if args["code"] == nil or args["code"] == 0 then if args["list"] == nil then table.push(text, table.concat{				'(,, , , , , , and  ', ending })		else			return values[args["list"]+1]		end	else		table.push(text, table.concat({			values[1],			values[2],			values[3],			values[4],			values[5],			values[6],			values[7],			values[8],		}, ','))	end	return table.concat(text) end

return p