FANDOM


local roblox_urls = require('Module:RobloxUrls')
local links = require('Module:Links')
local utils = require("Module:Utils")
local infobox_utils = require('Module:InfoboxUtils')
 
local categorize = utils.categorize(0)
 
local p = {}
 
function p._format_title(args)
	if args.id == '{{{id}}}' then
		return infobox_utils.error_message("<code>id</code> parameter missing")
	elseif tonumber(args.id) then
		return links.plain_external_link(roblox_urls.group(args.id), args.name)
	else
		return infobox_utils.error_message("<code>id</code> must be an integer.")
	end
end
 
p.format_title = utils.make_wrapper_function(p._format_title)
 
function p._format_owner(args)
	return infobox_utils.player_link(args.owner)
end
 
p.format_owner = utils.make_wrapper_function(p._format_owner)
 
function p._format_activity(args)
	local activity = args.activity:lower()
	if activity == 'active' then
		return "Active" .. categorize("Active groups")
	elseif activity == 'inactive' or activity == 'not active' then
		return "Inactive" .. categorize("Inactive groups")
	elseif activity == 'abandoned' or activity == 'dead' then
		return "Abandoned" .. categorize("Abandoned groups")
	else
		return infobox_utils.error_message("<code>activity</code> must be 'active', 'inactive' or 'abandoned'")
	end
end
 
p.format_activity = utils.make_wrapper_function(p._format_activity)
 
function p._format_members(args)
	return infobox_utils.format_number(args.members, 1000, "Groups with less than 15000 members", 15000)
end
 
p.format_members = utils.make_wrapper_function(p._format_members)
 
return p

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.