View Single Post
11/11/20, 10:31 AM   #10
Baertram
Super Moderator
 
Baertram's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 4,979
With the new set item collections, is a GetNumSets() function possible now or do we need to "iterate" the setIds via GetNextItemSetCollectionId() until it returns 0/nil ?

Edit:
An answer from ZOs:
There is no index one could use to build that function but the following data will return the number of given "reconstructable" setIds and is build before addons are loaded:

Lua Code:
  1. local numSetIds = NonContiguousCount(ITEM_SET_COLLECTIONS_DATA_MANAGER.itemSetCollections)

But this will only provide the number of "reconstructable" sets available (excluding craftable ones, and other sets), not the real "highest set number in the game"!

For a total set number and data you are currently able to use the library: LibSets

Last edited by Baertram : 11/12/20 at 04:48 PM.
  Reply With Quote