changeset 68:cce68795f955

- microDungeon status should trigger a full update
author Nenue
date Sun, 02 Apr 2017 13:51:24 -0400
parents 96183f981acb
children 31de7e9e7849
files WorldPlan.lua
diffstat 1 files changed, 7 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/WorldPlan.lua	Sat Apr 01 08:17:30 2017 -0400
+++ b/WorldPlan.lua	Sun Apr 02 13:51:24 2017 -0400
@@ -295,13 +295,14 @@
 }
 
 function WorldPlanCore:SetCurrentMap(event)
-  local mapAreaID = GetCurrentMapAreaID()
+  local mapAreaID, isContinent = GetCurrentMapAreaID()
   if not mapAreaID then
     return
   end
   print('SetCurrentMap()', event, mapAreaID)
   local isBrokenIsle = BROKEN_ISLE_MAPS[mapAreaID]
-  local isContinent = (mapAreaID == BROKEN_ISLES_ID)
+
+  local mapFileName, textureHeight, textureWidth, isMicroDungeon, microDungeonMapName = GetMapInfo()
 
 
   if db.isContinentMap ~= isContinent then
@@ -310,13 +311,15 @@
     end
   end
   local isMapOpen = WorldMapFrame:IsShown()
-  local isNewMap = isMapOpen and (mapAreaID ~= db.currentMapID)
+  local isNewMap = isMapOpen and ((mapAreaID ~= db.currentMapID) or (isMapOpen ~= db.isMapOpen) or (db.isMicroDungeon ~= isMicroDungeon))
+
+  db.isMicroDungeon = isMicroDungeon
+  db.isMapOpen = isMapOpen
   db.currentMapID = mapAreaID
   db.isContinentMap = isContinent
   db.isBrokenIsle = isBrokenIsle
   db.useContinentType = (WorldMapDetailFrame:GetScale() < 1)
 
-
   for _, module in ipairs(db.OrderedModules) do
     if module.OnMapInfo then
       print('  |cFF00FFFF'..module:GetName() .. ':OnMapInfo()|r')