Module:Skill

local p = {}

local function newCat(catName) return  .. 'Category:' .. catName ..  end

-- actually parse the skill name here and generate categories function p.categories(frame) if not frame or not frame.args then return '' end local args = frame.args -- force skill text to lowercase to ensure easier comparisons local skill = string.lower(args[1]) -- if the skill is empty or not a string just return if not skill or skill == '' or type(skill) ~= 'string' then return '' end local cat = '' -- Score Boost 10% (with 10% or pure) if skill:find('increased by 10%%') then if skill:find('great becomes perfect') then cat = cat .. newCat('Note Boost (S) & Score Boost 10%') elseif skill:find('300 life recovery') then cat = cat .. newCat('300 Life Recovery & Score Boost 10%') elseif skill:find('will not decrease life') then cat = cat .. newCat('Damage Guard & Score Boost 10%') else cat = cat .. newCat('Score Boost 10%') end end

return cat end

return p