/
coordframe:EnableMouse(true) |
local coords = coordframe:CreateFontString(nil, "OVERLAY") |
coords:SetParent(coordframe) |
coords:SetFont("Interface\\AddOns\\PocketPlot\\media\\negotiate_free.ttf", 12) --temporary |
local frames = { "None", |
"Minimap", |
"DurabilityFrame", |
bg = {r = 0, g = 0, b = 0}, --border colors (red, green, blue) -- values are a range from 0-1 (0,0,0 is black and 1,1,1 is white) |
mmAlpha = 1, |
combHide = false, |
--mouseover = true, --set to false! |
alpha = 1, |
top = false, |
coords = true, |
coordSize = 16, |
classbg = false, |
classfont = false, |
textOffset = 0, |
insets = 4, |
strata = "BACKGROUND", |
level = 2, |
end |
end |
--[[local function ShowOnMouseover() |
MinimapZoneTextButton:SetAlpha(1) |
--MiniMapTrackingButton:SetAlpha(1) |
MiniMapTrackingButton:Show() |
MiniMapBattlefieldFrame:SetAlpha(1) |
MiniMapMailFrame:SetAlpha(1) |
MiniMapVoiceChatFrame:SetAlpha(1) |
MiniMapLFGFrame:SetAlpha(1) |
end |
local function HideOnMouseOut() |
MinimapZoneTextButton:SetAlpha(0) |
--MiniMapTrackingButton:SetAlpha(0) |
MiniMapTrackingButton:Hide() |
MiniMapBattlefieldFrame:SetAlpha(0) |
MiniMapMailFrame:SetAlpha(0) |
MiniMapVoiceChatFrame:SetAlpha(0) |
MiniMapLFGFrame:SetAlpha(0) |
end]] |
local function SetShape() |
Minimap:SetMaskTexture("Interface\\AddOns\\PocketPlot\\media\\"..db.shape) |
PocketPlot:SetBackdrop({ bgFile = "Interface\\AddOns\\PocketPlot\\media\\"..db.shape }) |
end) |
--TRACKING ICON/MENU |
--MiniMapTrackingButton:SetAlpha(0) |
MiniMapTrackingButtonBorder:SetAlpha(0) |
MiniMapTrackingButton:SetAlpha(0) |
MiniMapTrackingBackground:Hide() |
MiniMapTracking:ClearAllPoints() |
MiniMapTracking:SetPoint("BOTTOMLEFT", Minimap, "BOTTOMLEFT", -4, -5) --where the tracking icon/menu is located |
MinimapBorderTop:Hide() |
CombatHide() --Check to see if we should hide the minimap in combat |
--hide icons and zone text til mouseover |
--Minimap:SetScript("OnEnter", function() if db.mouseover then ShowOnMouseover() end end) |
--Minimap:SetScript("OnLeave", function() if db.mouseover then HideOnMouseOut() end end) |
MinimapCluster:EnableMouse(false) --so you can still click the game world/turn in the upper right corner |
coordframe:ClearAllPoints() |
if not db.top then |
if clockshown and not coordshown then |
TimeManagerClockButton:SetPoint("TOP", Minimap, "BOTTOM", 0, 0 + db.textOffset) |
TimeManagerClockButton:SetPoint("TOP", Minimap, "BOTTOM", 0, 0) |
clockTime:SetJustifyH("CENTER") |
end |
if coordshown and not clockshown then |
coords:SetJustifyH("CENTER") |
coordframe:SetPoint("TOP", Minimap, "BOTTOM", 0, 0 + db.textOffset) |
coordframe:SetPoint("TOP", Minimap, "BOTTOM", 0, 0) |
end |
if clockshown and coordshown then |
TimeManagerClockButton:SetPoint("TOPLEFT", Minimap, "BOTTOMLEFT", 2, 0 + db.textOffset) |
TimeManagerClockButton:SetPoint("TOPLEFT", Minimap, "BOTTOMLEFT", 2, 0) |
clockTime:SetJustifyH("LEFT") |
coords:SetJustifyH("RIGHT") |
coordframe:SetPoint("TOPRIGHT", Minimap, "BOTTOMRIGHT", 0, 0 + db.textOffset) |
coordframe:SetPoint("TOPRIGHT", Minimap, "BOTTOMRIGHT", 0, 0) |
end |
else |
if clockshown and not coordshown then |
TimeManagerClockButton:SetPoint("BOTTOM", Minimap, "TOP", 2, 0 + db.textOffset) |
TimeManagerClockButton:SetPoint("BOTTOM", Minimap, "TOP", 2, 0) |
clockTime:SetJustifyH("CENTER") |
end |
if coordshown and not clockshown then |
coords:SetJustifyH("CENTER") |
coordframe:SetPoint("BOTTOM", Minimap, "TOP", 0, 0 + db.textOffset) |
coordframe:SetPoint("BOTTOM", Minimap, "TOP", 0, 0) |
end |
if clockshown and coordshown then |
TimeManagerClockButton:SetPoint("BOTTOMLEFT", Minimap, "TOPLEFT", 0, 0 + db.textOffset) |
TimeManagerClockButton:SetPoint("BOTTOMLEFT", Minimap, "TOPLEFT", 0, 0) |
clockTime:SetJustifyH("LEFT") |
coords:SetJustifyH("RIGHT") |
coordframe:SetPoint("BOTTOMRIGHT", Minimap, "TOPRIGHT", 0, 0 + db.textOffset) |
coordframe:SetPoint("BOTTOMRIGHT", Minimap, "TOPRIGHT", 0, 0) |
end |
end |
end |
end, |
order = 23, |
}, |
textOffset = { |
name = "Offset", |
desc = "Vertical offset for the clock and coordinates.", |
type = "range", |
min = -25, |
max = 25, |
step = 1, |
get = function() return db.textOffset end, |
set = function(_,offset) |
db.textOffset = offset |
CoordPosition() |
end, |
order = 23.5, |
}, |
header3 = { |
name = "Frame Locations", |
type = "header", |
## Title: PocketPlot |
## Author: Seerah |
## Notes: Minimap customization |
## Version: 2.13 |
## Version: 2.12.1 |
## X-Category: Minimap |
## OptionalDeps: Ace3, LibSharedMedia-3.0, AceGUI-3.0-SharedMediaWidgets |
## SavedVariables: PocketPlotDB |