Misplaced Pages

Module:Video game reviews/data: Difference between revisions

Article snapshot taken from Wikipedia with creative commons attribution-sharealike license. Give it a read and then ask your questions in the chat. We can research this topic together.
< Module:Video game reviews Browse history interactively← Previous editNext edit →Content deleted Content added
Revision as of 21:19, 17 July 2014 view sourceJackmcbarn (talk | contribs)31,380 edits use order and mapping← Previous edit Revision as of 21:29, 17 July 2014 view source Jackmcbarn (talk | contribs)31,380 edits new format again - name and sortkeyNext edit →
Line 102: Line 102:
} }


local function makeOrderAndMapping(t) local function setupSortkeys(t)
local order, mapping = {}, {} local retval = {}
for k,v in ipairs(t) do for k,v in ipairs(t) do
order = v retval] = { name = v, sortkey = k }
mapping] = v
end end
return order, mapping return retval
end end


return { reviewers = setupSortkeys(reviewers), aggregators = setupSortkeys(aggregators), systems = setupSortkeys(systems) }
local order, mapping = {}, {}
order.reviewers, mapping.reviewers = makeOrderAndMapping(reviewers)
order.aggregators, mapping.aggregators = makeOrderAndMapping(aggregators)
order.systems, mapping.systems = makeOrderAndMapping(systems)

return { order = order, mapping = mapping }

Revision as of 21:29, 17 July 2014

Module documentation[view] [edit] [history] [purge]
WarningThis Lua module is used on approximately 15,000 pages and changes may be widely noticed. Test changes in the module's /sandbox or /testcases subpages, or in your own module sandbox. Consider discussing changes on the talk page before implementing them.
ProtectedThis module is subject to page protection. It is a highly visible module in use by a very large number of pages, or is substituted very frequently. Because vandalism or mistakes would affect many pages, and even trivial editing might cause substantial load on the servers, it is protected from editing.
This module depends on the following other modules:
CSSThis module uses TemplateStyles:
Related pages

This module implements the {{Video game reviews}} template. Please see the template page for usage instructions.

Tracking/maintenance category

The above documentation is transcluded from Module:Video game reviews/data/doc. (edit | history)
Editors can experiment in this module's sandbox (edit | diff) and testcases (create) pages.
Subpages of this module.

local reviewers = {
	{']', '1UP'},
	{']', 'Atrip'},
	{']', 'AdvGamers'},
	{']', 'Allgame'},
	{']', 'AAction'},
	{']', 'Amtix'},
	{']', 'CVG'},
	{']', 'CRASH'},
	{']', 'Destruct'},
	{']', 'Dragon'},
	{']', 'Edge'},
	{']', 'EGM'},
	{']', 'EuroG'},
	{']', 'Fam'},
	{']', 'G4'},
	{'GameCritics', 'GCritics'},
	{']', 'GameFan'},
	{']', 'GI'},
	{']', 'GamePro'},
	{']', 'GameRev'},
	{']', 'GMaster'},
	{']', 'GRadar'},
	{']', 'GSpot'},
	{']', 'GSpy'},
	{']', 'GTM'},
	{']', 'GT'},
	{'GameWire', 'GW'},
	{']', 'GameZone'},
	{']', 'GB'},
	{']', 'Hyper'},
	{']', 'IGN'},
	{']', 'Joystiq'},
	{']', 'MaxPC'},
	{']', 'N64'},
	{']', 'NGC'},
	{']', 'NG'},
	{'NintendoLife', 'NLife'},
	{']', 'NP'},
	{'Nintendo World Report', 'NWR'},
	{']', 'ONM'},
	{']', 'OPM'},
	{']', 'OPMUK'},
	{']', 'OPMAU'},
	{']', 'OXM'},
	{']', 'OXMUK'},
	{']', 'PALGN'},
	{']', 'PCF'},
	{']', 'PCGUK'},
	{']', 'PCGUS'},
	{']', 'PCPP'},
	{']', 'PCZone'},
	{']', 'Play'},
	{']', 'Poly'},
	{']', 'PSM'},
	{']', 'PSM3'},
	{']', 'RPG'},
	{']', 'SUser'},
	{']', 'TX'},
	{']', 'VG'},
	{']', 'XPlay'},
	{']', 'YSinclair'},
}

local aggregators = {
	{']','GR'},
	{']','MC'},
}

local systems = {
	{']','A2600'},
	{']','CV'},
	{']','DS'},
	{']','GB'},
	{']','GBA'},
	{']','GBC'},
	{']', 'GEN'},
	{']','iOS'},
	{']','N-G'},
	{']','N64'},
	{']','NES'},
	{']','NGC'},
	{']','NSHI'},
	{']','PC'},
	{']','PS'},
	{']','PS2'},
	{']','PS3'},
	{']','PS4'},
	{']','PSP'},
	{']','SDC'},
	{']','SGG'},
	{']','SNES'},
	{']','SMD'},
	{']','SMS'},
	{']','SSAT'},
	{']','TG16'},
	{']','VITA'},
	{']','XBOX'},
	{']','X360'},
	{']','XONE'},
	{']','WII'},
}

local function setupSortkeys(t)
	local retval = {}
	for k,v in ipairs(t) do
		retval] = { name = v, sortkey = k }
	end
	return retval
end

return { reviewers = setupSortkeys(reviewers), aggregators = setupSortkeys(aggregators), systems = setupSortkeys(systems) }
Categories: