Module:Ru Paul's Drag Race tables
Appearance
![]() | This module is rated as alpha. It is ready for third-party input, and may be used on a few pages to see if problems arise, but should be watched. Suggestions for new features or changes in their input and output mechanisms are welcome. |
This module implements {{Drag Race contestant table}} and {{Drag Race progress table}}. See the code for more details.
local p = {} --p stands for package
function p.main( frame )
templateFrame = frame:getParent()
contestantData = {}
ret = ''
for k, v in pairs( templateFrame.args ) do
ret = ret .. _getContestant(k) .. _getField(k) .. ' = ' .. v .. "\n"
end
return ret
end
local function _getContestant( k )
return string.gmatch( k, "contestant\s(\d+)" )
end
local function _getField( k )
return string.gmatch( k, "contestant\s\d+-(.*)")
end
return p