|
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 |
local nextAchievementId = achievementId while nextAchievementId ~= 0 do achievementId = nextAchievementId return achievementId end end return achievementIdend return true end while id ~= 0 do if completed then return true end -- This achievement was completed, but we want to show unearned, so see if there are any unearned achievements in this line else -- This achievement wasn't completed return true end -- Otherwise we only want to show earned achievements, so find the first completed achievement working backwards from this one end end -- Either this achievement wasn't a line, or everything in it was filtered. return falseendfunction ZO_GetAchievementIds(categoryIndex, subcategoryIndex, numAchievements, considerSearchResults) local result = {} if searchResults then local effectiveSubcategoryIndex = subcategoryIndex or ZO_ACHIEVEMENTS_ROOT_SUBCATEGORY searchResults = searchResults[categoryIndex][effectiveSubcategoryIndex] end for achievementIndex = 1, numAchievements do if not searchResults or searchResults[achievementIndex] then end end return resultend |