Thread Tools Display Modes
03/29/15, 04:46 PM   #1
SnowmanDK
 
SnowmanDK's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 161
Any way to get all map numbers for submaps?

Hi

I need to make a table of all submaps including the numbers.
Does a table already exist somewhere, or is there a way to get them without having to enter each and every one?

I need somthing like this for all zones:
Lua Code:
  1. [4] = {         -- Stormhaven
  2.         {28},   -- Bonesnap Ruins
  3.         {30},   -- Wayrest Sewers
  4.         {128}-- Portdun Watch
  5.         {129}-- Koeglin Mine
  6.         {130}-- Pariah Catacombs
  7.         {131}-- Farangel's Delve
  8.         {132}-- Bearclaw Mine
  9.         {133}-- Norvulk Ruins
  10.     },
  Reply With Quote
03/29/15, 05:14 PM   #2
circonian
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 613
Garkin made one & posted it here: http://www.esoui.com/forums/showthread.php?p=12693#post12693

Although yes you could do it yourself. I didn't log in & test this, but something like this would work:
Lua Code:
  1. local zoneTable = {}
  2. for zoneIndex = 1, 2000 do
  3.     local zoneName = GetZoneNameByIndex(zoneIndex)
  4.     if zoneName ~= "" then
  5.         zoneTable[zoneIndex] = zoneName
  6.     end
  7. end

Last edited by circonian : 03/29/15 at 05:21 PM.
  Reply With Quote
03/29/15, 05:23 PM   #3
SnowmanDK
 
SnowmanDK's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 161
Exactly what I need, thanks a lot

Case closed

Originally Posted by circonian View Post
Garkin made one & posted it here: http://www.esoui.com/forums/showthread.php?p=12693#post12693

Although yes you could do it yourself. I didn't log in & test this, but something like this would work:
Lua Code:
  1. local zoneTable = {}
  2. for zoneIndex = 1, 2000 do
  3.     local zoneName = GetZoneNameByIndex(zoneIndex)
  4.     if zoneName ~= "" then
  5.         zoneTable[zoneIndex] = zoneName
  6.     end
  7. end
  Reply With Quote

ESOUI » Developer Discussions » Lua/XML Help » Any way to get all map numbers for submaps?


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off