It does not output anything as numCollectibles at GetCollectibleCategoryInfo(COLLECTIBLE_CATEGORY_TYPE_DLC) returns 0
subCategories is 3 and unlockedCollectibles is 31 if you got eso+
Maybe this is intended, or a bug.
--- @return name string, numSubCatgories integer, numCollectibles integer, unlockedCollectibles integer, totalCollectibles integer, hidesLocked bool
Edit
It's intended!
You need to use the subcategories as well!
subCategory 3 is the DLC, subCategory 2 is the dungeon name as it seems.
--collectibleId|collectibleSubCategoryIndex|collectibleName
[154] = "154|3|Imperial City",
[215] = "215|3|Orsinium",
[254] = "254|3|Thieves Guild",
[306] = "306|3|Dark Brotherhood",
[593] = "593|3|Morrowind",
[1240] = "1240|3|Clockwork City",
[5107] = "5107|3|Summerset",
[5755] = "5755|3|Murkmire",
[5843] = "5843|3|Elsweyr",
[6920] = "6920|3|Dragonhold",
[7466] = "7466|3|Greymoor",
[8388] = "8388|3|Markarth",
|
Lua Code:
--- @return name string, numSubCatgories integer, numCollectibles integer, unlockedCollectibles integer, totalCollectibles integer, hidesLocked bool
local name, numSubCategories, numCollectibles, unlockedCollectibles, totalCollectibles, hidesLocked = GetCollectibleCategoryInfo(COLLECTIBLE_CATEGORY_TYPE_DLC)
d(string.format("[COLLECTIBLE_CATEGORY_TYPE_DLC]numSubCategories: %s, numCollectibles: %s, unlockedCollectibles: %s, totalCollectibles: %s", tostring(numSubCategories), tostring(numCollectibles), tostring(unlockedCollectibles), tostring(totalCollectibles)))
for collectibleSubCategoryIndex=1, numSubCategories do
--- @return name string, numCollectibles integer, unlockedCollectibles integer, totalCollectibles integer
local name, numCollectibles, unlockedCollectibles, totalCollectibles = GetCollectibleSubCategoryInfo(COLLECTIBLE_CATEGORY_TYPE_DLC, collectibleSubCategoryIndex)
for i=1, numCollectibles do
local collectibleId = GetCollectibleId(COLLECTIBLE_CATEGORY_TYPE_DLC, collectibleSubCategoryIndex, i)
--- @return name string, description string, icon textureName, deprecatedLockedIcon textureName, unlocked bool, purchasable bool, isActive bool, categoryType [CollectibleCategoryType|#CollectibleCategoryType], hint string
local collectibleName, _, _, _, unlocked = GetCollectibleInfo(collectibleId) -- Will return true or false. If the user unlocked throught ESO+ without buying DLC it will return true.
d("DLC ".. zo_strformat("<<C:1>>", collectibleName) .. "(".. collectibleId .. ") unlocked : " .. tostring(unlocked))
end
end
end
Returns e.g.
DLC Elsweyr^N( 5843) unlocked : true
You need to use zo_strformat("<<C:1>>", collectibleName) to remove the gender suffix stuff like ^N etc.
But somehow some DLC/Chapter are missing then, like Wolfhunter.
And COLLECTIBLE_CATEGORY_TYPE_CHAPTER is not returning anything if I try to use it...