Module:Character

--

local p = {}

-- Gender

local genderParameters = { ["female"] = "Female ", ["male"] = "Male ", ["unknown"] = "Unknown ", ["missing"] = "MissingGame ", }

function p.gender(frame) local result = '' for gend in mw.text.gsplit(string.lower(frame.args[1]), ',') do		if genderParameters[gend] then -- skip invalid values result = result .. genderParameters[gend] .. ' '			else result = '      ' end end return string.sub(result, 1, -8) -- remove last whitespace end

-- Race

local raceParameters = { ["altmer"] = "Altmer ", ["high elf"] = "Altmer ", ["argonian"] = "Argonian ", ["bosmer"] = "Bosmer ", ["wood elf"] = "Bosmer ", ["breton"] = "Breton ", ["dunmer"] = "Dunmer ", ["dark elf"] = "Dunmer ", ["imperial"] = "Imperial ", ["khajiit"] = "Khajiit ", ["nord"] = "Nord ", ["orsimer"] = "Orsimer ", ["orc"] = "Orsimer ", ["redguard"] = "Redguard ", ["elder"] = "Elder ", ["werewolf"] = "Werewolf ", ["dremora"] = "Dremora ", ["akaviri"] = "Akaviri ", ["vampire"] = "Vampire ", ["vampire race"] = "Vampire ", ["vampire lord"] = "Vampire Lord ", ["dark seducer"] = "Dark Seducer ", ["golden saint"] = "Golden Saint ", ["snow elf"] = "Snow Elf ", ["dwemer"] = "Dwemer ", ["hagraven"] = "Hagraven ", ["ehlnofey"] = "Ehlnofey ", ["xivkyn"] = "Xivkyn ", ["maormer"] = "Maormer ", ["sea elf"] = "Maormer ", ["herne"] = "Herne ", ["skaafin"] = "Skaafin ", ["auroran"] = "Auroran ", ["spiderkith"] = "Spiderkith ", ["chimer"] = "Chimer ", ["ayleid"] = "Ayleid ", ["unknown"] = "Unknown ", ["missing"] = "MissingGame ", }

function p.race(frame) local result = '' for rac in mw.text.gsplit(string.lower(frame.args[1]), ',') do		if raceParameters[rac] then -- skip invalid values result = result .. raceParameters[rac] .. ' '			else result = '      ' end end return string.sub(result, 1, -8) -- remove last whitespace end

return p

--