I've popped in from time to time to get some help with a custom addon you guys wrote for me a couple years ago. The function is mainly to hide flight path icons on the world map (not the flight map), though it tends to catch a few other icons too, such as cities/towns, PvP vendors, even Sentinax and similar things. Unfortunately since 8.0 it doesn't work anymore, not even the macro I have for identifying Map POIs.
I'm certainly no addon developer (though I really should learn the basics at this stage so I don't have to keep pestering you all), but you guys have been such tremendous help to me in the past. If you have the time, mind helping an old fan out to update his addon for the expansion launch?
This is the current code:
for i = 1, GetNumMapLandmarks() do
local landmarkType, name = C_WorldMap.GetMapLandmarkInfo(i)
if landmarkType == 0 or landmarkType == 5 or landmarkType == 6 or landmarkType == 9 or landmarkType == 46 or landmarkType == 48 or landmarkType == 178 or landmarkType == 179 or landmarkType == 180 or landmarkType == 188 or landmarkType == 194
local poi = _G["WorldMapFramePOI"..i]
if poi then
-- The "if poi then" check is probably not needed, but better safe than sorry!
local mapAreaID = GetCurrentMapAreaID()
local taskInfo = C_TaskQuest.GetQuestsForPlayerByMapID(mapAreaID)
local numTaskPOIs = 0;
if(taskInfo ~= nil) then
numTaskPOIs = #taskInfo;
local taskIconCount = 1;
if ( numTaskPOIs > 0 ) then
for _, info in next, taskInfo do
local taskPOIName = "WorldMapFrameTaskPOI"..taskIconCount;
local taskPOI = _G[taskPOIName];
taskIconCount = taskIconCount + 1;
And here's the macro to scan the map for POIs:
/run for i = 1, GetNumMapLandmarks() do local _, name, _, textureIndex = GetMapLandmarkInfo(i) print(i, textureIndex, name) end
Sometimes I've been able to change the POIs to fix it on my own, but this time nothing works. The macro doesn't return anything. From what I can tell, the only icon change to the maps are the added zeppelin/boat world travel markers, but there must be some underlying syntax change that's beyond my capabilities. Any ideas?