Module:Skills

---	Skills stores details of Risk of Rain 2' character skills. --	--	@module		skills --	@alias		p --	@author		Paradoxzyx --	@require	Module:Skills/Data --	@release	stable -- local p = {}

local data = require("Module:Skills/Data") local all_skills = data.skills

---	Gets the formatted skill description. --	@function		p.Skill --	@param			{table} frame Frame object --	@return			{string} Preprocessed wikitext of skill description function p.Skill(frame) return frame:preprocess(all_skills[frame.args[1]].Desc) end

---	Gets the formatted skill description for tooltips. --	@function		p.SkillTooltip --	@param			{table} frame Frame object --	@return			{string} Preprocessed wikitext of skill description function p.SkillTooltip(frame) local data = all_skills[frame.args[1]] if data == nil then return frame:preprocess("" .. frame.args[1] .. " is not a valid skill. ") end local str = data.Desc if (data.Survivor) then str = str .. " Survivor: " .. data.Survivor .. ""	end return frame:preprocess(str) end

---	Given skill, gets survivor --	@function		p.SkillSurvivor --	@param			{table} frame Frame object --	@return			{string} Preprocessed wikitext of skill survivor name function p.SkillSurvivor(frame) return frame:preprocess(all_skills[frame.args[1]].Survivor) end

return p --