API GetNumDungeonMapLevels

From Warcraft Wiki
Jump to navigation Jump to search

This is somewhat of a misnomer as it does not directly return the number of levels on the map. Rather, it returns an array containing the sub map numbers (levels) available on the current world map. The array will have one entry for each level on the current map, with each value indicating an "area" or "submap" number. To get the count of levels/submaps, examine the size of the returned array (#levels)

levels = GetNumDungeonMapLevels();

Parameters

none


Returns

levels
array of Integers - Array containing each sub map number


Details

Return value is an array where each entry represents the number of an option in the drop down for 'areas' or 'submaps' within a given zone. The total number of levels/areas/submaps is represented by the number of entries in the array. Current selected option is available through GetCurrentMapDungeonLevel.

Patch changes

  • Legion Patch 7.0.3 (2016-07-19): changed to return an array of the actual level/submap number themselves, instead of a simple count of the number of levels as the name might imply