View Single Post
03/03/16, 04:23 PM   #9
Wandamey
Guest
Posts: n/a
I tried the functions before the ability2 def and it seems that :
progressionIndex is the order you learn your skills, is it? seems like it. (hmm maybe not... just the unlocked ones in order)

but whatever I enter for GetSkillAbilityIndicesFromProgressionIndex(int) as an int, it returns 0,2,2
even if I feed it a string.

(English client, btw and that is on PTS right now)
GetAbilityProgressionInfo(int) this is fine, gives me the right name/morph/rank...



if it's really broken, only one way to rewrite it as the SKILLS_WINDOW table only fills with current selected skillLine or the last opened with the skill window it seems...

local SkillTable = {}
--(or global, well at least addon level)

On startup and on skill updates : (sorry for the indents but at least it's copypastable)
function addon:RegisterAbilityIdToIndexesTable()

SkillTable = {} -- not sure how ids work with upgrades and all, why not wipe each time

for skillType = 1, GetNumSkillTypes() do
for skillLineIndex = 1, GetNumSkillLines(skillType) do
for abilityIndex = 1, GetNumSkillAbilities(skillType, skillLineIndex) do
SkillTable[GetSkillAbilityId(skillType, skillLineIndex, abilityIndex)] = {skillType, skillLineIndex, abilityIndex}
end
end
end

end
and to get your indexes back :

function addon:GetMyIndexesBack(abilityID)
return SkillTable[abilityID][1], SkillTable[abilityID][2], SkillTable[abilityID][3]
end

Last edited by Wandamey : 03/03/16 at 06:57 PM.