Quantcast

tooltip visual update and fixed classbar options

Steven Jackson [07-17-14 - 05:51]
tooltip visual update and fixed classbar options
Filename
Interface/AddOns/SVUI/packages/dock/common/toolbar.lua
Interface/AddOns/SVUI/packages/laborer/common/archaeology.lua
Interface/AddOns/SVUI/packages/map/common/worldmap.lua
Interface/AddOns/SVUI/packages/tip/SVTip.lua
Interface/AddOns/SVUI/packages/unit/frames/units.lua
Interface/AddOns/SVUI/scripts/pvp.lua
Interface/AddOns/SVUI_StyleOMatic/addons/worldmap.lua
diff --git a/Interface/AddOns/SVUI/packages/dock/common/toolbar.lua b/Interface/AddOns/SVUI/packages/dock/common/toolbar.lua
index 51462fa..8b7e4a4 100644
--- a/Interface/AddOns/SVUI/packages/dock/common/toolbar.lua
+++ b/Interface/AddOns/SVUI/packages/dock/common/toolbar.lua
@@ -73,7 +73,7 @@ local Button_OnLeave = function(b)
 end

 local Button_OnClick = function(self)
-	if InCombatLockdown() then return end
+	if InCombatLockdown() then return end
 	local linkedFrame = self.FrameName
 	if linkedFrame and _G[linkedFrame] then
 		SuperDockWindowRight.FrameName = linkedFrame
@@ -182,7 +182,7 @@ function MOD:CreateBasicToolButton(name,texture,onclick,frameName,isdefault)
 	if isdefault == true then
 		MOD.DefaultWindow = fName;
 	end
-	button.IsOpen = isdefault or false;
+	button.IsOpen = isdefault and true or false;
 	button:SetScript("OnEnter",Button_OnEnter)
 	button:SetScript("OnLeave",Button_OnLeave)
 	button:SetScript("OnClick",clickFunction)
diff --git a/Interface/AddOns/SVUI/packages/laborer/common/archaeology.lua b/Interface/AddOns/SVUI/packages/laborer/common/archaeology.lua
index bb6f237..d508775 100644
--- a/Interface/AddOns/SVUI/packages/laborer/common/archaeology.lua
+++ b/Interface/AddOns/SVUI/packages/laborer/common/archaeology.lua
@@ -267,6 +267,9 @@ do
 					ArchSiteFound = nil
 				end
 			end
+			if(event == "ARTIFACT_DIG_SITE_UPDATED" or event == "ARTIFACT_DIGSITE_COMPLETE") then
+				UpdateArtifactCache()
+			end
 		elseif(ArchCanSurvey and (event == "ARTIFACT_HISTORY_READY" or event == "CURRENCY_DISPLAY_UPDATE" or event == "ARTIFACT_COMPLETE")) then
 			UpdateArtifactCache()
 		end
diff --git a/Interface/AddOns/SVUI/packages/map/common/worldmap.lua b/Interface/AddOns/SVUI/packages/map/common/worldmap.lua
index 9812ffd..d4b6059 100644
--- a/Interface/AddOns/SVUI/packages/map/common/worldmap.lua
+++ b/Interface/AddOns/SVUI/packages/map/common/worldmap.lua
@@ -38,63 +38,63 @@ GET ADDON DATA
 ]]--
 local SuperVillain, L = unpack(select(2, ...));
 local MOD = SuperVillain.Registry:Expose('SVMap');
-local NewHook = hooksecurefunc;
-
+local NewHook = hooksecurefunc
+local Initialized = false
 local function SetLargeWorldMap()
-	if InCombatLockdown() then return end;
-	if SuperVillain.db.SVMap.tinyWorldMap then
+	if InCombatLockdown() then return end
+	if SuperVillain.db.SVMap.tinyWorldMap == true then
 		WorldMapFrame:SetParent(SuperVillain.UIParent)
 		WorldMapFrame:EnableMouse(false)
 		WorldMapFrame:EnableKeyboard(false)
 		WorldMapFrame:SetScale(1)
 		if WorldMapFrame:GetAttribute('UIPanelLayout-area') ~= 'center'then
 			SetUIPanelAttribute(WorldMapFrame, "area", "center")
-		end;
+		end
 		if WorldMapFrame:GetAttribute('UIPanelLayout-allowOtherPanels') ~= true then
 			SetUIPanelAttribute(WorldMapFrame, "allowOtherPanels", true)
-		end
-	end;
+		end
+	end
 	WorldMapFrameSizeUpButton:Hide()
 	WorldMapFrameSizeDownButton:Show()
-end;
+end

 local function SetQuestWorldMap()
-	if InCombatLockdown() then return end;
-	if SuperVillain.db.SVMap.tinyWorldMap then
+	if InCombatLockdown() then return end
+	if SuperVillain.db.SVMap.tinyWorldMap == true then
 		WorldMapFrame:SetParent(SuperVillain.UIParent)
 		WorldMapFrame:EnableMouse(false)
 		WorldMapFrame:EnableKeyboard(false)
 		if WorldMapFrame:GetAttribute('UIPanelLayout-area') ~= 'center'then
 			SetUIPanelAttribute(WorldMapFrame, "area", "center")
-		end;
+		end
 		if WorldMapFrame:GetAttribute('UIPanelLayout-allowOtherPanels') ~= true then
 			SetUIPanelAttribute(WorldMapFrame, "allowOtherPanels", true)
 		end
-	end;
+	end
 	WorldMapFrameSizeUpButton:Hide()
 	WorldMapFrameSizeDownButton:Show()
-end;
+end

 local function SetSmallWorldMap()
-	if InCombatLockdown() then return end;
+	if InCombatLockdown() then return end
 	WorldMapLevelDropDown:ClearAllPoints()
 	WorldMapLevelDropDown:Point("TOPLEFT", WorldMapDetailFrame, "TOPLEFT", -10, -4)
 	WorldMapFrameSizeUpButton:Show()
 	WorldMapFrameSizeDownButton:Hide()
-end;
+end

 local function AdjustMapLevel()
-	if InCombatLockdown()then return end;
+	if InCombatLockdown()then return end
 	WorldMapFrame:SetFrameLevel(2)
   	WorldMapDetailFrame:SetFrameLevel(4)
   	WorldMapFrame:SetFrameStrata('HIGH')
   	WorldMapArchaeologyDigSites:SetFrameLevel(6)
   	WorldMapArchaeologyDigSites:SetFrameStrata('DIALOG')
-end;
+end

 local function AdjustMapSize()
-	if InCombatLockdown() then return end;
-	if MOD.db.tinyWorldMap then
+	if InCombatLockdown() then return end
+	if SuperVillain.db.SVMap.tinyWorldMap == true then
 		if WORLDMAP_SETTINGS.size == WORLDMAP_FULLMAP_SIZE then
 			SetLargeWorldMap()
 		elseif WORLDMAP_SETTINGS.size == WORLDMAP_WINDOWED_SIZE then
@@ -112,32 +112,32 @@ local function AdjustMapSize()
 			WorldMapFrame_SetQuestMapView()
 		end
 		BlackoutWorld:SetTexture(0, 0, 0, 1)
-	end;
+	end
 	AdjustMapLevel()
-end;
+end

 local function CheckMovement()
-	if(not WorldMapFrame:IsShown()) then return end;
+	if(not WorldMapFrame:IsShown()) then return end
 	if GetUnitSpeed("player") ~= 0 then
 		WorldMapFrame:SetAlpha(MOD.db.mapAlpha)
 	else
 		WorldMapFrame:SetAlpha(1)
 	end
-end;
+end

 function MOD:PLAYER_REGEN_ENABLED()
 	self:UnregisterEvent('PLAYER_REGEN_ENABLED')
 	WorldMapFrameSizeDownButton:Enable()
 	WorldMapFrameSizeUpButton:Enable()
-end;
+end

 function MOD:PLAYER_REGEN_DISABLED()
 	WorldMapFrameSizeDownButton:Disable()
 	WorldMapFrameSizeUpButton:Disable()
-end;
+end

 local function UpdateWorldMapCoords()
-	if(not WorldMapFrame:IsShown() or not SVUI_WorldMapCoords) then return end;
+	if(not WorldMapFrame:IsShown() or not SVUI_WorldMapCoords) then return end
 	local a, b = IsInInstance()
 	local c, d = GetPlayerMapPosition("player")
 	c = parsefloat(100 * c, 2)
@@ -146,7 +146,7 @@ local function UpdateWorldMapCoords()
 		SVUI_WorldMapCoords.playerCoords:SetText(PLAYER..":   "..c..", "..d)
 	else
 		SVUI_WorldMapCoords.playerCoords:SetText("")
-	end;
+	end
 	local e = WorldMapDetailFrame:GetEffectiveScale()
 	local f = WorldMapDetailFrame:GetWidth()
 	local g = WorldMapDetailFrame:GetHeight()
@@ -161,10 +161,10 @@ local function UpdateWorldMapCoords()
 	else
 		SVUI_WorldMapCoords.mouseCoords:SetText("")
 	end
-end;
+end

 function MOD:UpdateWorldMapConfig()
-	if InCombatLockdown()then return end;
+	if InCombatLockdown()then return end
 	if(not MOD.WorldMapHooked) then
 		NewHook("WorldMap_ToggleSizeUp", AdjustMapSize)
 		NewHook("WorldMap_ToggleSizeDown", SetSmallWorldMap)
@@ -179,32 +179,40 @@ function MOD:UpdateWorldMapConfig()
 		end
 	elseif(not MOD.MovingTimer) then
 		MOD.MovingTimer = SuperVillain:ExecuteLoop(CheckMovement, 0.2)
-	end;
+	end
 	AdjustMapSize()
-end;
+end

 local ResetDropDownList_Hook = function(self)
 	DropDownList1:ClearAllPoints()
 	DropDownList1:Point("TOPRIGHT",self,"BOTTOMRIGHT",-17,-4)
-end;
+end

 local WorldMapFrameOnShow_Hook = function()
-	if InCombatLockdown()then return end;
-	AdjustMapLevel()
-end;
+	if InCombatLockdown()then return end
+	if(not SuperVillain.db.SVMap.tinyWorldMap and not Initialized) then
+      WorldMap_ToggleSizeUp()
+      Initialized = true
+    end
+    AdjustMapLevel()
+end

 function MOD:LoadWorldMap()
 	setfenv(WorldMapFrame_OnShow, setmetatable({ UpdateMicroButtons = function() end }, { __index = _G }))
+
 	WorldMapShowDropDown:Point('BOTTOMRIGHT',WorldMapPositioningGuide,'BOTTOMRIGHT',-2,-4)
 	WorldMapZoomOutButton:Point("LEFT",WorldMapZoneDropDown,"RIGHT",0,4)
 	WorldMapLevelUpButton:Point("TOPLEFT",WorldMapLevelDropDown,"TOPRIGHT",-2,8)
 	WorldMapLevelDownButton:Point("BOTTOMLEFT",WorldMapLevelDropDown,"BOTTOMRIGHT",-2,2)
+
+	WorldMapFrame:SetParent(SuperVillain.UIParent)
 	WorldMapFrame:SetFrameLevel(4)
-	WorldMapDetailFrame:SetFrameLevel(6)
 	WorldMapFrame:SetFrameStrata('HIGH')
+	WorldMapDetailFrame:SetFrameLevel(6)

 	WorldMapFrame:HookScript('OnShow', WorldMapFrameOnShow_Hook)
 	WorldMapZoneDropDownButton:HookScript('OnClick', ResetDropDownList_Hook)
+
 	self:RegisterEvent('PLAYER_REGEN_ENABLED')
 	self:RegisterEvent('PLAYER_REGEN_DISABLED')

diff --git a/Interface/AddOns/SVUI/packages/tip/SVTip.lua b/Interface/AddOns/SVUI/packages/tip/SVTip.lua
index db07595..3a2aeff 100644
--- a/Interface/AddOns/SVUI/packages/tip/SVTip.lua
+++ b/Interface/AddOns/SVUI/packages/tip/SVTip.lua
@@ -28,7 +28,7 @@ local table 	= _G.table;
 --[[ STRING METHODS ]]--
 local find, format, match, sub, gsub = string.find, string.format, string.match, string.sub, string.gsub;
 --[[ MATH METHODS ]]--
-local floor = math.floor;
+local floor,min = math.floor, math.min;
 --[[ TABLE METHODS ]]--
 local twipe, tconcat = table.wipe, table.concat;
 --[[
@@ -646,6 +646,17 @@ local _hook_OnTipCleared = function(self)
 	self.itemCleared = nil
 end

+local _hook_OnTipShow = function(self)
+	local width,height = self:GetSize()
+	local heightScale = min(64, height)
+	local widthScale = min(128, width)
+	local heightWidth = widthScale * 0.35
+	self.SuperBorder[1]:SetSize(widthScale,heightWidth)
+	self.SuperBorder[2]:SetSize(heightScale,heightScale)
+	self.SuperBorder[3]:SetSize(heightScale,heightScale)
+	self.SuperBorder[4]:SetSize(widthScale,heightWidth)
+end
+
 local _hook_OnItemRef = function(link,text,button,chatFrame)
 	if find(link,"^spell:") then
 		local ref = sub(link,7)
@@ -708,9 +719,9 @@ function MOD:Load()
 	GameTooltip:HookScript("OnTooltipSetUnit", _hook_GameTooltip_OnTooltipSetUnit)
 	GameTooltipStatusBar:HookScript("OnValueChanged", _hook_GameTooltipStatusBar_OnValueChanged)
 	self:RegisterEvent("MODIFIER_STATE_CHANGED", TooltipModifierChangeHandler)
-	local MINI_BG = [[Interface\Addons\SVUI\assets\artwork\Template\Tooltip\MINITIP-BG]]
-	local MINI_LEFT = [[Interface\Addons\SVUI\assets\artwork\Template\Tooltip\MINITIP-LEFT]]
-	local MINI_RIGHT = [[Interface\Addons\SVUI\assets\artwork\Template\Tooltip\MINITIP-RIGHT]]
+	-- local MINI_BG = [[Interface\Addons\SVUI\assets\artwork\Template\Tooltip\MINITIP-BG]]
+	-- local MINI_LEFT = [[Interface\Addons\SVUI\assets\artwork\Template\Tooltip\MINITIP-LEFT]]
+	-- local MINI_RIGHT = [[Interface\Addons\SVUI\assets\artwork\Template\Tooltip\MINITIP-RIGHT]]
 	for _, tooltip in pairs(tooltips) do
 		if(tooltip.SuperBorder) then return end
 		local mask = CreateFrame("Frame", nil, tooltip)
@@ -724,17 +735,15 @@ function MOD:Load()
 		mask[1]:SetBlendMode("BLEND")
 		mask[1]:SetAlpha(0.65)
 		mask[2] = mask:CreateTexture(nil, "BACKGROUND")
-		mask[2]:SetPoint("TOPLEFT", mask, "TOPRIGHT", 0, 0)
-		mask[2]:SetPoint("BOTTOMLEFT", mask, "BOTTOMRIGHT", 0, 0)
-		mask[2]:SetWidth(mask:GetHeight() * 2.25)
+		mask[2]:SetPoint("LEFT", mask, "RIGHT", 0, 0)
+		mask[2]:SetSize(64,64)
 		mask[2]:SetTexture(TT_RIGHT)
 		mask[2]:SetVertexColor(0,0,0)
 		mask[2]:SetBlendMode("BLEND")
 		mask[2]:SetAlpha(0.75)
 		mask[3] = mask:CreateTexture(nil, "BACKGROUND")
-		mask[3]:SetPoint("TOPRIGHT", mask, "TOPLEFT", 0, 0)
-		mask[3]:SetPoint("BOTTOMRIGHT", mask, "BOTTOMLEFT", 0, 0)
-		mask[3]:SetWidth(mask:GetHeight() * 2.25)
+		mask[3]:SetPoint("RIGHT", mask, "LEFT", 0, 0)
+		mask[3]:SetSize(64,64)
 		mask[3]:SetTexture(TT_LEFT)
 		mask[3]:SetVertexColor(0,0,0)
 		mask[3]:SetBlendMode("BLEND")
@@ -759,6 +768,7 @@ function MOD:Load()
 		tooltip.SetBackdrop = function() end
 		tooltip.SetBackdropColor = function() end
 		tooltip.SetBackdropBorderColor = function() end
+		tooltip:HookScript("OnShow", _hook_OnTipShow)
 	end
 end
 SuperVillain.Registry:NewPackage(MOD, "SVTip")
\ No newline at end of file
diff --git a/Interface/AddOns/SVUI/packages/unit/frames/units.lua b/Interface/AddOns/SVUI/packages/unit/frames/units.lua
index 4c89af4..5a28d21 100644
--- a/Interface/AddOns/SVUI/packages/unit/frames/units.lua
+++ b/Interface/AddOns/SVUI/packages/unit/frames/units.lua
@@ -184,41 +184,48 @@ local UpdatePlayerFrame = function(self)
             end
             if(self.ClassBar) then
                 local classBar = self[self.ClassBar];
-                if not db.classbar.detachFromFrame then
-                    if classBar.Avatar then
-                        classBar.Avatar:SetScale(0.000001)
-                        classBar.Avatar:SetAlpha(0)
-                    end
-                else
-                    classBarWidth = db.classbar.detachedWidth;
-                    if not classBar.Avatar then
-                        classBar:Point("TOPLEFT", self, "BOTTOMLEFT", 0, -2)
-                        SuperVillain:SetSVMovable(classBar, "ClassBar_MOVE", L["Classbar"], nil, nil, nil, "ALL, SOLO")
-                    else
-                        classBar.Avatar:SetScale(1)
-                        classBar.Avatar:SetAlpha(1)
-                    end
-                end
+
                 if USE_CLASSBAR then
+                    if not db.classbar.detachFromFrame then
+                        if classBar.Avatar then
+                            classBar.Avatar:SetScale(0.000001)
+                            classBar.Avatar:SetAlpha(0)
+                        end
+                    else
+                        classBarWidth = db.classbar.detachedWidth;
+                        if not classBar.Avatar then
+                            classBar:Point("TOPLEFT", self, "BOTTOMLEFT", 0, -2)
+                            SuperVillain:SetSVMovable(classBar, "ClassBar_MOVE", L["Classbar"], nil, nil, nil, "ALL, SOLO")
+                        else
+                            classBar.Avatar:SetScale(1)
+                            classBar.Avatar:SetAlpha(1)
+                        end
+                    end
                     if(not self:IsElementEnabled(self.ClassBar)) then
                         self:EnableElement(self.ClassBar)
                     end
                     classBar:Show()
+                    self.ClassBar:Show()
                 else
                     if(self:IsElementEnabled(self.ClassBar)) then
                         self:DisableElement(self.ClassBar)
                     end
                     classBar:Hide()
+                    self.ClassBar:Hide()
                 end
             end
             if(self.HyperCombo) then
-                if not self:IsElementEnabled("HyperCombo") then
-                    self:EnableElement("HyperCombo")
-                end
-            else
-                if self:IsElementEnabled("HyperCombo") then
-                    self:DisableElement("HyperCombo")
-                end
+                if USE_CLASSBAR then
+                    if not self:IsElementEnabled("HyperCombo") then
+                        self:EnableElement("HyperCombo")
+                    end
+                    self.HyperCombo:Show()
+                else
+                    if self:IsElementEnabled("HyperCombo") then
+                        self:DisableElement("HyperCombo")
+                    end
+                    self.HyperCombo:Hide()
+                end
             end
         end
     end
diff --git a/Interface/AddOns/SVUI/scripts/pvp.lua b/Interface/AddOns/SVUI/scripts/pvp.lua
index 58b389a..1a890bb 100644
--- a/Interface/AddOns/SVUI/scripts/pvp.lua
+++ b/Interface/AddOns/SVUI/scripts/pvp.lua
@@ -50,6 +50,25 @@ local function EnteringBattleGround()
 	end
 end

+local function UpdateBattleGroundLinks()
+	SVUI_PVPComm:Show()
+	local numButtons = 1
+	local points = GetNumMapLandmarks()
+	for i = 1, points do
+		if(numButtons <= 6) then
+			local name, description, icon, _, _, _, active = GetMapLandmarkInfo(i)
+			local buttonName = ("SVUI_PVPCommButton"):format(numButtons)
+			local button = _G[buttonName]
+			button.name = name
+			button.description = description
+			button.Text:SetText(name)
+			button:SetFontString(button.Text)
+			button:Show()
+			numButtons = numButtons + 1
+		end
+	end
+end
+
 local function ExitingBattleGround()
 	for i = 1, 6 do
 		local buttonName = ("SVUI_PVPCommButton"):format(numButtons)
diff --git a/Interface/AddOns/SVUI_StyleOMatic/addons/worldmap.lua b/Interface/AddOns/SVUI_StyleOMatic/addons/worldmap.lua
index 0d89694..85dd9e4 100644
--- a/Interface/AddOns/SVUI_StyleOMatic/addons/worldmap.lua
+++ b/Interface/AddOns/SVUI_StyleOMatic/addons/worldmap.lua
@@ -20,13 +20,21 @@ local MOD = SuperVillain.Registry:Expose('SVStyle');
 HELPERS
 ##########################################################
 ]]--
+local function AdjustMapLevel()
+  if InCombatLockdown()then return end
+    WorldMapFrame:SetFrameLevel(2)
+    WorldMapDetailFrame:SetFrameLevel(4)
+    WorldMapFrame:SetFrameStrata('HIGH')
+    WorldMapArchaeologyDigSites:SetFrameLevel(6)
+    WorldMapArchaeologyDigSites:SetFrameStrata('DIALOG')
+end
 local function WorldMap_SmallView()
   WorldMapFrame.Panel:ClearAllPoints()
   WorldMapFrame.Panel:SetAllPoints(WorldMapFrame)
   WorldMapFrame.backdrop:ClearAllPoints()
   WorldMapFrame.backdrop:Point("TOPLEFT", WorldMapFrame.Panel, 2, 2)
   WorldMapFrame.backdrop:Point("BOTTOMRIGHT", WorldMapFrame.Panel, 2, -2)
-end;
+end
 local function WorldMap_FullView()
   WorldMapFrame.Panel:ClearAllPoints()
   WorldMapFrame.Panel:Point("TOPLEFT", WorldMapDetailFrame, "TOPLEFT", -12, 70)
@@ -34,7 +42,7 @@ local function WorldMap_FullView()
   WorldMapFrame.backdrop:ClearAllPoints()
   WorldMapFrame.backdrop:Point("TOPLEFT", WorldMapFrame.Panel, 2, 2)
   WorldMapFrame.backdrop:Point("BOTTOMRIGHT", WorldMapFrame.Panel, 2, -2)
-end;
+end
 local function WorldMap_QuestView()
   WorldMap_FullView()
   if not WorldMapQuestDetailScrollFrame.Panel then
@@ -46,7 +54,7 @@ local function WorldMap_QuestView()
     WorldMapQuestDetailScrollFrame.spellTex:SetPoint("TOPLEFT", WorldMapQuestDetailScrollFrame.Panel, 'TOPLEFT', 2, -2)
     WorldMapQuestDetailScrollFrame.spellTex:Size(586, 310)
     WorldMapQuestDetailScrollFrame.spellTex:SetTexCoord(0, 1, 0.02, 1)
-  end;
+  end
   if not WorldMapQuestRewardScrollFrame.Panel then
     WorldMapQuestRewardScrollFrame:SetPanelTemplate("Inset")
     WorldMapQuestRewardScrollFrame.Panel:Point("BOTTOMRIGHT", 22, -4)
@@ -55,7 +63,7 @@ local function WorldMap_QuestView()
     WorldMapQuestRewardScrollFrame.spellTex:SetPoint("TOPLEFT", WorldMapQuestRewardScrollFrame.Panel, 'TOPLEFT', 2, -2)
     WorldMapQuestRewardScrollFrame.spellTex:Size(585, 310)
     WorldMapQuestRewardScrollFrame.spellTex:SetTexCoord(0, 1, 0.02, 1)
-  end;
+  end
   if not WorldMapQuestScrollFrame.Panel then
     WorldMapQuestScrollFrame:SetPanelTemplate("Inset")
     WorldMapQuestScrollFrame.Panel:Point("TOPLEFT", 0, 2)
@@ -66,19 +74,21 @@ local function WorldMap_QuestView()
     WorldMapQuestScrollFrame.spellTex:Size(520, 1033)
     WorldMapQuestScrollFrame.spellTex:SetTexCoord(0, 1, 0.02, 1)
   end
-end;
+end
 local function WorldMap_OnShow()
   WorldMapFrame:Formula409()
   if not SuperVillain.db.SVMap.tinyWorldMap then
-     BlackoutWorld:SetTexture(0, 0, 0, 1)
-  end;
+    BlackoutWorld:SetTexture(0, 0, 0, 1)
+  else
+    BlackoutWorld:SetTexture(nil)
+  end
   if WORLDMAP_SETTINGS.size == WORLDMAP_FULLMAP_SIZE then
     WorldMap_FullView()
   elseif WORLDMAP_SETTINGS.size == WORLDMAP_WINDOWED_SIZE then
     WorldMap_SmallView()
   elseif WORLDMAP_SETTINGS.size == WORLDMAP_QUESTLIST_SIZE then
     WorldMap_QuestView()
-  end;
+  end
   WorldMapFrameAreaLabel:SetFontTemplate(nil, 50, "OUTLINE")
   WorldMapFrameAreaLabel:SetShadowOffset(2, -2)
   WorldMapFrameAreaLabel:SetTextColor(0.90, 0.8294, 0.6407)
@@ -87,20 +97,21 @@ local function WorldMap_OnShow()
   WorldMapFrameAreaPetLevels:SetFontTemplate(nil, 25, 'OUTLINE')
   WorldMapZoneInfo:SetFontTemplate(nil, 27, "OUTLINE")
   WorldMapZoneInfo:SetShadowOffset(2, -2)
-  if InCombatLockdown() then return end;
+  if InCombatLockdown() then return end
   WorldMapFrame:SetFrameLevel(2)
   WorldMapDetailFrame:SetFrameLevel(4)
   WorldMapFrame:SetFrameStrata('HIGH')
   WorldMapArchaeologyDigSites:SetFrameLevel(6)
   WorldMapArchaeologyDigSites:SetFrameStrata('DIALOG')
-end;
+  AdjustMapLevel()
+end
 --[[
 ##########################################################
 WORLDMAP STYLER
 ##########################################################
 ]]--
 local function WorldMapQuestStyle()
-  if SuperVillain.db.SVStyle.blizzard.enable ~= true or SuperVillain.db.SVStyle.blizzard.worldmap ~= true then return end;
+  if SuperVillain.db.SVStyle.blizzard.enable ~= true or SuperVillain.db.SVStyle.blizzard.worldmap ~= true then return end
   WorldMapFrame:SetFrameLevel(2)
   MOD:ApplyScrollStyle(WorldMapQuestScrollFrameScrollBar)
   MOD:ApplyScrollStyle(WorldMapQuestDetailScrollFrameScrollBar, 4)
@@ -133,7 +144,7 @@ local function WorldMapQuestStyle()
   hooksecurefunc("WorldMapFrame_SetQuestMapView", WorldMap_QuestView)
   hooksecurefunc("WorldMap_ToggleSizeUp", WorldMap_OnShow)
   BlackoutWorld:SetParent(WorldMapFrame.backdrop)
-end;
+end
 --[[
 ##########################################################
 STYLE LOADING