Created
March 2, 2013 23:02
-
-
Save zachwlewis/5073674 to your computer and use it in GitHub Desktop.
Gets a characters profession information and print it out.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function GetProfessionInformation() | |
local prof1, prof2, archaeology, fishing, cooking, firstAid = GetProfessions() | |
if prof1 ~= nil then PrintProfessionInformation(prof1) end | |
if prof2 ~= nil then PrintProfessionInformation(prof2) end | |
if archaeology ~= nil then PrintProfessionInformation(archaeology) end | |
if fishing ~= nil then PrintProfessionInformation(fishing) end | |
if cooking ~= nil then PrintProfessionInformation(cooking) end | |
if firstAid ~= nil then PrintProfessionInformation(firstAid) end | |
end | |
function PrintProfessionInformation(index) | |
local name, icon, skillLevel, maxSkillLevel, numAbilities, spelloffset, skillLine, skillModifier = GetProfessionInfo(index) | |
print(name.." ("..skillLevel.."/"..maxSkillLevel..")") | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment