frame strata option added for all visual elements
This commit is contained in:
parent
2edca9b11e
commit
242c45b8c4
@ -1235,3 +1235,25 @@ Gladdy.newDefaults = {
|
||||
["castBarYOffset"] = -30.5,
|
||||
},
|
||||
}
|
||||
|
||||
Gladdy.frameStrata = {
|
||||
BACKGROUND = L["Background"] .. "(0)",
|
||||
LOW = L["Low"] .. "(1)",
|
||||
MEDIUM = L["Medium"] .. "(2)",
|
||||
HIGH = L["High"] .. "(3)",
|
||||
DIALOG = L["Dialog"] .. "(4)",
|
||||
FULLSCREEN = L["Fullscreen"] .. "(5)",
|
||||
FULLSCREEN_DIALOG = L["Fullscreen Dialog"] .. "(6)",
|
||||
TOOLTIP = L["Tooltip"] .. "(7)",
|
||||
}
|
||||
|
||||
Gladdy.frameStrataSorting = {
|
||||
[1] = "BACKGROUND",
|
||||
[2] = "LOW",
|
||||
[3] = "MEDIUM",
|
||||
[4] = "HIGH",
|
||||
[5] = "DIALOG",
|
||||
[6] = "FULLSCREEN",
|
||||
[7] = "FULLSCREEN_DIALOG",
|
||||
[8] = "TOOLTIP",
|
||||
}
|
@ -395,7 +395,7 @@ function Gladdy:CreateMover(frame, xConfig, yConfig, name, points, width, height
|
||||
frame:EnableMouse(false)
|
||||
frame:SetMovable(true)
|
||||
frame.mover = CreateFrame("Frame", nil, frame, BackdropTemplateMixin and "BackdropTemplate")
|
||||
frame.mover:SetFrameStrata("DIALOG")
|
||||
frame.mover:SetFrameStrata("TOOLTIP")
|
||||
frame.mover:SetPoint(points[1], frame, points[2], xOffset or 0, yOffset or 0)
|
||||
frame.mover:SetHeight(height or frame:GetHeight())
|
||||
frame.mover:SetWidth(width or frame:GetWidth())
|
||||
@ -412,6 +412,7 @@ function Gladdy:CreateMover(frame, xConfig, yConfig, name, points, width, height
|
||||
frame.mover.border:SetBackdrop({ edgeFile = Gladdy:SMFetch("border", "highlightBorderStyle"), edgeSize = 2 })
|
||||
frame.mover.border:SetAllPoints(frame.mover)
|
||||
frame.mover.border:SetBackdropBorderColor(0,1,0,1)
|
||||
frame.mover.border:SetFrameStrata("TOOLTIP")
|
||||
|
||||
frame.mover.text = frame.mover.border:CreateFontString(nil, "ARTWORK", "GameFontHighlightSmall")
|
||||
frame.mover.text:SetText(name)
|
||||
|
@ -6,7 +6,9 @@ local Gladdy = LibStub("Gladdy")
|
||||
local L = Gladdy.L
|
||||
local ACDFrame = Gladdy:NewModule("Arena Countdown", nil, {
|
||||
countdown = true,
|
||||
arenaCountdownSize = 256
|
||||
arenaCountdownSize = 256,
|
||||
arenaCountdownFrameStrata = "HIGH",
|
||||
arenaCountdownFrameLevel = 50,
|
||||
})
|
||||
|
||||
function ACDFrame:OnEvent(event, ...)
|
||||
@ -51,6 +53,11 @@ function ACDFrame:Initialize()
|
||||
self.faction = UnitFactionGroup("player")
|
||||
end
|
||||
|
||||
function ACDFrame:UpdateFrameOnce()
|
||||
self.ACDNumFrame:SetFrameStrata(Gladdy.db.arenaCountdownFrameStrata)
|
||||
self.ACDNumFrame:SetFrameLevel(Gladdy.db.arenaCountdownFrameLevel)
|
||||
end
|
||||
|
||||
function ACDFrame.OnUpdate(self, elapse)
|
||||
if (self.countdown > 0 and Gladdy.db.countdown) then
|
||||
self.hidden = false;
|
||||
@ -182,5 +189,26 @@ function ACDFrame:GetOptions()
|
||||
step = 16,
|
||||
width = "full",
|
||||
}),
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 5,
|
||||
},
|
||||
arenaCountdownFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 6,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
}),
|
||||
arenaCountdownFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 0,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 7,
|
||||
width = "full",
|
||||
}),
|
||||
}
|
||||
end
|
||||
|
@ -52,6 +52,10 @@ local Auras = Gladdy:NewModule("Auras", nil, {
|
||||
auraInterruptYOffset = 0,
|
||||
auraInterruptSize = 60 + 20 + 1,
|
||||
auraInterruptWidthFactor = 0.9,
|
||||
auraFrameStrata = "MEDIUM",
|
||||
auraFrameLevel = 5,
|
||||
auraInterruptFrameStrata = "MEDIUM",
|
||||
auraInterruptFrameLevel = 5,
|
||||
})
|
||||
|
||||
function Auras:Initialize()
|
||||
@ -223,6 +227,16 @@ function Auras:UpdateFrame(unit)
|
||||
|
||||
if Gladdy.db.auraDetached then
|
||||
width, height = Gladdy.db.auraSize * Gladdy.db.auraWidthFactor, Gladdy.db.auraSize
|
||||
|
||||
auraFrame:SetFrameStrata(Gladdy.db.auraFrameStrata)
|
||||
auraFrame:SetFrameLevel(Gladdy.db.auraFrameLevel)
|
||||
auraFrame.frame:SetFrameStrata(Gladdy.db.auraFrameStrata)
|
||||
auraFrame.frame:SetFrameLevel(Gladdy.db.auraFrameLevel)
|
||||
auraFrame.cooldown:SetFrameStrata(Gladdy.db.auraFrameStrata)
|
||||
auraFrame.cooldown:SetFrameLevel(Gladdy.db.auraFrameLevel + 1)
|
||||
auraFrame.cooldownFrame:SetFrameStrata(Gladdy.db.auraFrameStrata)
|
||||
auraFrame.cooldownFrame:SetFrameLevel(Gladdy.db.auraFrameLevel + 2)
|
||||
|
||||
auraFrame:ClearAllPoints()
|
||||
Gladdy:SetPosition(auraFrame, unit, "auraXOffset", "auraYOffset", true, Auras)
|
||||
if (unit == "arena1") then
|
||||
@ -235,6 +249,16 @@ function Auras:UpdateFrame(unit)
|
||||
end
|
||||
else
|
||||
width, height = Gladdy.db.classIconSize * Gladdy.db.classIconWidthFactor, Gladdy.db.classIconSize
|
||||
|
||||
auraFrame:SetFrameStrata(Gladdy.db.classIconFrameStrata)
|
||||
auraFrame:SetFrameLevel(Gladdy.db.classIconFrameLevel + 1)
|
||||
auraFrame.frame:SetFrameStrata(Gladdy.db.classIconFrameStrata)
|
||||
auraFrame.frame:SetFrameLevel(Gladdy.db.classIconFrameLevel + 1)
|
||||
auraFrame.cooldown:SetFrameStrata(Gladdy.db.classIconFrameStrata)
|
||||
auraFrame.cooldown:SetFrameLevel(Gladdy.db.classIconFrameLevel + 2)
|
||||
auraFrame.cooldownFrame:SetFrameStrata(Gladdy.db.classIconFrameStrata)
|
||||
auraFrame.cooldownFrame:SetFrameLevel(Gladdy.db.classIconFrameLevel + 3)
|
||||
|
||||
auraFrame:ClearAllPoints()
|
||||
auraFrame:SetPoint("TOPLEFT", Gladdy.modules["Class Icon"].frames[unit], "TOPLEFT")
|
||||
if auraFrame.mover then
|
||||
@ -285,6 +309,16 @@ function Auras:UpdateInterruptFrame(unit)
|
||||
|
||||
if Gladdy.db.auraInterruptDetached then
|
||||
width, height = Gladdy.db.auraInterruptSize * Gladdy.db.auraInterruptWidthFactor, Gladdy.db.auraInterruptSize
|
||||
|
||||
interruptFrame:SetFrameStrata(Gladdy.db.auraInterruptFrameStrata)
|
||||
interruptFrame:SetFrameLevel(Gladdy.db.auraInterruptFrameLevel)
|
||||
interruptFrame.frame:SetFrameStrata(Gladdy.db.auraInterruptFrameStrata)
|
||||
interruptFrame.frame:SetFrameLevel(Gladdy.db.auraInterruptFrameLevel)
|
||||
interruptFrame.cooldown:SetFrameStrata(Gladdy.db.auraInterruptFrameStrata)
|
||||
interruptFrame.cooldown:SetFrameLevel(Gladdy.db.auraInterruptFrameLevel + 1)
|
||||
interruptFrame.cooldownFrame:SetFrameStrata(Gladdy.db.auraInterruptFrameStrata)
|
||||
interruptFrame.cooldownFrame:SetFrameLevel(Gladdy.db.auraInterruptFrameLevel + 2)
|
||||
|
||||
interruptFrame:ClearAllPoints()
|
||||
Gladdy:SetPosition(interruptFrame, unit, "auraInterruptXOffset", "auraInterruptYOffset", true, Auras)
|
||||
if (unit == "arena1") then
|
||||
@ -298,6 +332,16 @@ function Auras:UpdateInterruptFrame(unit)
|
||||
else
|
||||
if Gladdy.db.auraDetached then
|
||||
width, height = Gladdy.db.auraSize * Gladdy.db.auraWidthFactor, Gladdy.db.auraSize
|
||||
|
||||
interruptFrame:SetFrameStrata(Gladdy.db.auraFrameStrata)
|
||||
interruptFrame:SetFrameLevel(Gladdy.db.auraFrameLevel)
|
||||
interruptFrame.frame:SetFrameStrata(Gladdy.db.auraFrameStrata)
|
||||
interruptFrame.frame:SetFrameLevel(Gladdy.db.auraFrameLevel)
|
||||
interruptFrame.cooldown:SetFrameStrata(Gladdy.db.auraFrameStrata)
|
||||
interruptFrame.cooldown:SetFrameLevel(Gladdy.db.auraFrameLevel + 1)
|
||||
interruptFrame.cooldownFrame:SetFrameStrata(Gladdy.db.auraFrameStrata)
|
||||
interruptFrame.cooldownFrame:SetFrameLevel(Gladdy.db.auraFrameLevel + 2)
|
||||
|
||||
interruptFrame:ClearAllPoints()
|
||||
interruptFrame:SetAllPoints(self.frames[unit])
|
||||
if interruptFrame.mover then
|
||||
@ -305,6 +349,16 @@ function Auras:UpdateInterruptFrame(unit)
|
||||
end
|
||||
else
|
||||
width, height = Gladdy.db.classIconSize * Gladdy.db.classIconWidthFactor, Gladdy.db.classIconSize
|
||||
|
||||
interruptFrame:SetFrameStrata(Gladdy.db.classIconFrameStrata)
|
||||
interruptFrame:SetFrameLevel(Gladdy.db.classIconFrameLevel + 1)
|
||||
interruptFrame.frame:SetFrameStrata(Gladdy.db.classIconFrameStrata)
|
||||
interruptFrame.frame:SetFrameLevel(Gladdy.db.classIconFrameLevel + 1)
|
||||
interruptFrame.cooldown:SetFrameStrata(Gladdy.db.classIconFrameStrata)
|
||||
interruptFrame.cooldown:SetFrameLevel(Gladdy.db.classIconFrameLevel + 2)
|
||||
interruptFrame.cooldownFrame:SetFrameStrata(Gladdy.db.classIconFrameStrata)
|
||||
interruptFrame.cooldownFrame:SetFrameLevel(Gladdy.db.classIconFrameLevel + 3)
|
||||
|
||||
interruptFrame:ClearAllPoints()
|
||||
interruptFrame:SetPoint("TOPLEFT", Gladdy.modules["Class Icon"].frames[unit], "TOPLEFT")
|
||||
if interruptFrame.mover then
|
||||
@ -702,6 +756,34 @@ function Auras:GetOptions()
|
||||
order = 22,
|
||||
width = "full",
|
||||
}),
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 30,
|
||||
},
|
||||
auraFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
disabled = function()
|
||||
return not Gladdy.db.auraDetached
|
||||
end,
|
||||
order = 32,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
auraFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
disabled = function()
|
||||
return not Gladdy.db.auraDetached
|
||||
end,
|
||||
min = 0,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 33,
|
||||
width = "full",
|
||||
}),
|
||||
}
|
||||
},
|
||||
detachedInterruptMode = {
|
||||
@ -778,6 +860,34 @@ function Auras:GetOptions()
|
||||
order = 22,
|
||||
width = "full",
|
||||
}),
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 30,
|
||||
},
|
||||
auraInterruptFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
disabled = function()
|
||||
return not Gladdy.db.auraDetached
|
||||
end,
|
||||
order = 32,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
auraInterruptFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
disabled = function()
|
||||
return not Gladdy.db.auraDetached
|
||||
end,
|
||||
min = 0,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 33,
|
||||
width = "full",
|
||||
}),
|
||||
}
|
||||
},
|
||||
cooldown = {
|
||||
|
@ -50,6 +50,8 @@ local BuffsDebuffs = Gladdy:NewModule("Buffs and Debuffs", nil, {
|
||||
buffsBorderColorDisease = Gladdy:GetAuraTypeColor()["disease"],
|
||||
buffsBorderColorForm = Gladdy:GetAuraTypeColor()["form"],
|
||||
buffsBorderColorAura = Gladdy:GetAuraTypeColor()["aura"],
|
||||
buffFrameStrata = "MEDIUM",
|
||||
buffsFrameLevel = 9,
|
||||
})
|
||||
|
||||
local spellSchoolToOptionValueTable
|
||||
@ -232,11 +234,15 @@ end
|
||||
|
||||
function BuffsDebuffs:CreateFrame(unit)
|
||||
local debuffFrame = CreateFrame("Frame", "GladdyDebuffs" .. unit, Gladdy.buttons[unit])
|
||||
debuffFrame:SetFrameStrata(Gladdy.db.buffFrameStrata)
|
||||
debuffFrame:SetFrameLevel(Gladdy.db.buffsFrameLevel)
|
||||
debuffFrame:SetMovable(true)
|
||||
debuffFrame:SetHeight(Gladdy.db.buffsIconSize)
|
||||
debuffFrame:SetWidth(1)
|
||||
debuffFrame.unit = unit
|
||||
local buffFrame = CreateFrame("Frame", "GladdyBuffs" .. unit, Gladdy.buttons[unit])
|
||||
buffFrame:SetFrameStrata(Gladdy.db.buffFrameStrata)
|
||||
buffFrame:SetFrameLevel(Gladdy.db.buffsFrameLevel)
|
||||
buffFrame:SetMovable(true)
|
||||
buffFrame:SetHeight(Gladdy.db.buffsIconSize)
|
||||
buffFrame:SetWidth(1)
|
||||
@ -271,6 +277,11 @@ local function styleIcon(aura, auraType)
|
||||
aura.cooldowncircle:SetAlpha(Gladdy.db.buffsCooldownAlpha)
|
||||
end
|
||||
|
||||
aura:SetFrameStrata(Gladdy.db.buffFrameStrata)
|
||||
aura:SetFrameLevel(Gladdy.db.buffsFrameLevel)
|
||||
aura.cooldowncircle:SetFrameLevel(Gladdy.db.buffsFrameLevel + 1)
|
||||
aura.overlay:SetFrameLevel(Gladdy.db.buffsFrameLevel + 2)
|
||||
|
||||
aura.border:SetTexture(Gladdy.db.buffsBorderStyle)
|
||||
aura.border:SetVertexColor(spellSchoolToOptionValue(aura.spellSchool))
|
||||
aura.cooldown:SetFont(Gladdy:SMFetch("font", "buffsFont"), (Gladdy.db.buffsIconSize/2 - 1) * Gladdy.db.buffsFontScale, "OUTLINE")
|
||||
@ -388,18 +399,19 @@ function BuffsDebuffs:AddAura(unit, spellID, auraType, duration, timeLeft, stack
|
||||
else
|
||||
aura = CreateFrame("Frame")
|
||||
aura:EnableMouse(false)
|
||||
aura:SetFrameLevel(3)
|
||||
aura:SetFrameStrata(Gladdy.db.buffFrameStrata)
|
||||
aura:SetFrameLevel(Gladdy.db.buffsFrameLevel)
|
||||
aura.texture = aura:CreateTexture(nil, "BACKGROUND")
|
||||
aura.texture:SetMask("Interface\\AddOns\\Gladdy\\Images\\mask")
|
||||
aura.texture:SetAllPoints(aura)
|
||||
aura.cooldowncircle = CreateFrame("Cooldown", nil, aura, "CooldownFrameTemplate")
|
||||
aura.cooldowncircle:SetFrameLevel(4)
|
||||
aura.cooldowncircle:SetFrameLevel(Gladdy.db.buffsFrameLevel + 1)
|
||||
aura.cooldowncircle.noCooldownCount = true -- disable OmniCC
|
||||
aura.cooldowncircle:SetAllPoints(aura)
|
||||
aura.cooldowncircle:SetReverse(true)
|
||||
aura.cooldowncircle:SetHideCountdownNumbers(true)
|
||||
aura.overlay = CreateFrame("Frame", nil, aura)
|
||||
aura.overlay:SetFrameLevel(5)
|
||||
aura.overlay:SetFrameLevel(Gladdy.db.buffsFrameLevel + 2)
|
||||
aura.overlay:SetAllPoints(aura)
|
||||
aura.border = aura.overlay:CreateTexture(nil, "OVERLAY")
|
||||
aura.border:SetAllPoints(aura)
|
||||
@ -878,6 +890,35 @@ function BuffsDebuffs:GetOptions()
|
||||
}),
|
||||
},
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 6,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
buffFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
buffsFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 0,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
debuffList = {
|
||||
|
@ -41,6 +41,8 @@ local Castbar = Gladdy:NewModule("Cast Bar", 70, {
|
||||
castBarTimerFormat = "LEFT",
|
||||
castBarSparkEnabled = true,
|
||||
castBarSparkColor = { r = 1, g = 1, b = 1, a = 1 },
|
||||
castBarFrameStrata = "MEDIUM",
|
||||
castBarFrameLevel = 5,
|
||||
})
|
||||
|
||||
function Castbar:Initialize()
|
||||
@ -60,19 +62,24 @@ function Castbar:CreateFrame(unit)
|
||||
castBar:EnableMouse(false)
|
||||
castBar:SetMovable(true)
|
||||
castBar.unit = unit
|
||||
castBar:SetFrameStrata(Gladdy.db.castBarFrameStrata)
|
||||
castBar:SetFrameLevel(Gladdy.db.castBarFrameLevel)
|
||||
|
||||
castBar.backdrop = CreateFrame("Frame", nil, castBar, BackdropTemplateMixin and "BackdropTemplate")
|
||||
castBar.backdrop:SetAllPoints(castBar)
|
||||
castBar.backdrop:SetBackdrop({ edgeFile = Gladdy:SMFetch("border", "castBarBorderStyle"),
|
||||
edgeSize = Gladdy.db.castBarBorderSize })
|
||||
castBar.backdrop:SetBackdropBorderColor(Gladdy.db.castBarBorderColor.r, Gladdy.db.castBarBorderColor.g, Gladdy.db.castBarBorderColor.b, Gladdy.db.castBarBorderColor.a)
|
||||
castBar.backdrop:SetFrameLevel(1)
|
||||
castBar.backdrop:SetFrameStrata(Gladdy.db.castBarFrameStrata)
|
||||
castBar.backdrop:SetFrameLevel(Gladdy.db.castBarFrameLevel - 1)
|
||||
|
||||
castBar.bar = CreateFrame("StatusBar", nil, castBar)
|
||||
castBar.bar:SetStatusBarTexture(Gladdy:SMFetch("statusbar", "castBarTexture"))
|
||||
castBar.bar:SetStatusBarColor(Gladdy.db.castBarColor.r, Gladdy.db.castBarColor.g, Gladdy.db.castBarColor.b, Gladdy.db.castBarColor.a)
|
||||
castBar.bar:SetMinMaxValues(0, 100)
|
||||
castBar.bar:SetFrameLevel(0)
|
||||
castBar.bar:SetFrameStrata(Gladdy.db.castBarFrameStrata)
|
||||
castBar.bar:SetFrameLevel(Gladdy.db.castBarFrameLevel)
|
||||
|
||||
castBar.spark = castBar:CreateTexture(nil, "OVERLAY")
|
||||
castBar.spark:SetTexture("Interface\\CastingBar\\UI-CastingBar-Spark")
|
||||
@ -88,6 +95,8 @@ function Castbar:CreateFrame(unit)
|
||||
castBar.bg:SetAllPoints(castBar.bar)
|
||||
|
||||
castBar.icon = CreateFrame("Frame", nil, castBar)
|
||||
castBar.icon:SetFrameStrata(Gladdy.db.castBarFrameStrata)
|
||||
castBar.icon:SetFrameLevel(Gladdy.db.castBarFrameLevel)
|
||||
castBar.icon.texture = castBar.icon:CreateTexture(nil, "BACKGROUND")
|
||||
castBar.icon.texture:SetMask("Interface\\AddOns\\Gladdy\\Images\\mask")
|
||||
castBar.icon.texture:SetAllPoints(castBar.icon)
|
||||
@ -129,6 +138,15 @@ function Castbar:UpdateFrame(unit)
|
||||
return
|
||||
end
|
||||
|
||||
castBar:SetFrameStrata(Gladdy.db.castBarFrameStrata)
|
||||
castBar:SetFrameLevel(Gladdy.db.castBarFrameLevel)
|
||||
castBar.backdrop:SetFrameStrata(Gladdy.db.castBarFrameStrata)
|
||||
castBar.backdrop:SetFrameLevel(Gladdy.db.castBarFrameLevel - 1)
|
||||
castBar.bar:SetFrameStrata(Gladdy.db.castBarFrameStrata)
|
||||
castBar.bar:SetFrameLevel(Gladdy.db.castBarFrameLevel)
|
||||
castBar.icon:SetFrameStrata(Gladdy.db.castBarFrameStrata)
|
||||
castBar.icon:SetFrameLevel(Gladdy.db.castBarFrameLevel)
|
||||
|
||||
castBar:SetWidth(Gladdy.db.castBarWidth)
|
||||
castBar:SetHeight(Gladdy.db.castBarHeight)
|
||||
castBar.backdrop:SetBackdrop({ edgeFile = Gladdy:SMFetch("border", "castBarBorderStyle"),
|
||||
@ -793,6 +811,35 @@ function Castbar:GetOptions()
|
||||
}),
|
||||
}
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 6,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
castBarFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
castBarFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 1,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
@ -13,6 +13,8 @@ local Classicon = Gladdy:NewModule("Class Icon", 81, {
|
||||
classIconSpecIcon = false,
|
||||
classIconXOffset = 0,
|
||||
classIconYOffset = 0,
|
||||
classIconFrameStrata = "MEDIUM",
|
||||
classIconFrameLevel = 5,
|
||||
})
|
||||
|
||||
local classIconPath = "Interface\\Addons\\Gladdy\\Images\\Classes\\"
|
||||
@ -111,6 +113,9 @@ function Classicon:UpdateFrame(unit)
|
||||
return
|
||||
end
|
||||
|
||||
classIcon:SetFrameStrata(Gladdy.db.classIconFrameStrata)
|
||||
classIcon:SetFrameLevel(Gladdy.db.classIconFrameLevel)
|
||||
|
||||
classIcon:SetWidth(Gladdy.db.classIconSize * Gladdy.db.classIconWidthFactor)
|
||||
classIcon:SetHeight(Gladdy.db.classIconSize)
|
||||
|
||||
@ -239,29 +244,37 @@ function Classicon:GetOptions()
|
||||
position = {
|
||||
type = "group",
|
||||
name = L["Position"],
|
||||
order = 1,
|
||||
order = 3,
|
||||
args = {
|
||||
headerPosition = {
|
||||
type = "header",
|
||||
name = L["Position"],
|
||||
order = 5,
|
||||
},
|
||||
classIconPos = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Icon position"],
|
||||
desc = L["This changes positions with trinket"],
|
||||
order = 6,
|
||||
values = {
|
||||
["LEFT"] = L["Left"],
|
||||
["RIGHT"] = L["Right"],
|
||||
},
|
||||
classIconXOffset = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Horizontal offset"],
|
||||
order = 11,
|
||||
min = -800,
|
||||
max = 800,
|
||||
step = 0.1,
|
||||
width = "full",
|
||||
}),
|
||||
classIconYOffset = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Vertical offset"],
|
||||
order = 12,
|
||||
min = -800,
|
||||
max = 800,
|
||||
step = 0.1,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
border = {
|
||||
type = "group",
|
||||
name = L["Border"],
|
||||
order = 1,
|
||||
order = 2,
|
||||
args = {
|
||||
headerBorder = {
|
||||
type = "header",
|
||||
@ -283,6 +296,35 @@ function Classicon:GetOptions()
|
||||
}),
|
||||
},
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 4,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
classIconFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
classIconFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 0,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
@ -14,6 +14,8 @@ local CombatIndicator = Gladdy:NewModule("Combat Indicator", nil, {
|
||||
ciYOffset = -31,
|
||||
ciBorderStyle = "Interface\\AddOns\\Gladdy\\Images\\Border_rounded_blp",
|
||||
ciBorderColor = { r = 0, g = 0, b = 0, a = 1 },
|
||||
ciFrameStrata = "HIGH",
|
||||
ciFrameLevel = 5,
|
||||
})
|
||||
|
||||
function CombatIndicator:Initialize()
|
||||
@ -36,7 +38,8 @@ function CombatIndicator:CreateFrame(unit)
|
||||
local ciFrame = CreateFrame("Frame", "GladdyCombatindicator" .. unit, button)
|
||||
ciFrame:EnableMouse(false)
|
||||
ciFrame:SetMovable(true)
|
||||
ciFrame:SetFrameStrata("HIGH")
|
||||
ciFrame:SetFrameStrata(Gladdy.db.ciFrameStrata)
|
||||
ciFrame:SetFrameLevel(Gladdy.db.ciFrameLevel)
|
||||
ciFrame:SetHeight(Gladdy.db.ciSize)
|
||||
ciFrame:SetWidth(Gladdy.db.ciSize * Gladdy.db.ciWidthFactor)
|
||||
|
||||
@ -60,6 +63,10 @@ function CombatIndicator:UpdateFrame(unit)
|
||||
if (not button or not ciFrame) then
|
||||
return
|
||||
end
|
||||
|
||||
ciFrame:SetFrameStrata(Gladdy.db.ciFrameStrata)
|
||||
ciFrame:SetFrameLevel(Gladdy.db.ciFrameLevel)
|
||||
|
||||
ciFrame:SetHeight(Gladdy.db.ciSize)
|
||||
ciFrame:SetWidth(Gladdy.db.ciSize * Gladdy.db.ciWidthFactor)
|
||||
ciFrame.border:SetTexture(Gladdy.db.ciBorderStyle)
|
||||
@ -166,7 +173,7 @@ function CombatIndicator:GetOptions()
|
||||
position = {
|
||||
type = "group",
|
||||
name = L["Position"],
|
||||
order = 4,
|
||||
order = 3,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
@ -196,7 +203,7 @@ function CombatIndicator:GetOptions()
|
||||
border = {
|
||||
type = "group",
|
||||
name = L["Border"],
|
||||
order = 4,
|
||||
order = 2,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
@ -218,6 +225,35 @@ function CombatIndicator:GetOptions()
|
||||
}),
|
||||
},
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 5,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
ciFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
ciFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 0,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
@ -67,6 +67,8 @@ local Cooldowns = Gladdy:NewModule("Cooldowns", nil, {
|
||||
cooldownDisableCircle = false,
|
||||
cooldownCooldownAlpha = 1,
|
||||
cooldownCooldowns = getDefaultCooldown(),
|
||||
cooldownFrameStrata = "MEDIUM",
|
||||
cooldownFrameLevel = 3,
|
||||
})
|
||||
|
||||
function Cooldowns:Initialize()
|
||||
@ -95,10 +97,13 @@ function Cooldowns:CreateFrame(unit)
|
||||
local spellCooldownFrame = CreateFrame("Frame", nil, button)
|
||||
spellCooldownFrame:EnableMouse(false)
|
||||
spellCooldownFrame:SetMovable(true)
|
||||
spellCooldownFrame:SetFrameStrata(Gladdy.db.cooldownFrameStrata)
|
||||
spellCooldownFrame:SetFrameLevel(Gladdy.db.cooldownFrameLevel)
|
||||
for x = 1, 14 do
|
||||
local icon = CreateFrame("Frame", nil, spellCooldownFrame)
|
||||
icon:EnableMouse(false)
|
||||
icon:SetFrameLevel(3)
|
||||
icon:SetFrameStrata(Gladdy.db.cooldownFrameStrata)
|
||||
icon:SetFrameLevel(Gladdy.db.cooldownFrameLevel)
|
||||
icon.texture = icon:CreateTexture(nil, "BACKGROUND")
|
||||
icon.texture:SetMask("Interface\\AddOns\\Gladdy\\Images\\mask")
|
||||
icon.texture:SetAllPoints(icon)
|
||||
@ -106,14 +111,16 @@ function Cooldowns:CreateFrame(unit)
|
||||
icon.cooldown = CreateFrame("Cooldown", nil, icon, "CooldownFrameTemplate")
|
||||
icon.cooldown.noCooldownCount = true
|
||||
|
||||
icon.cooldown:SetFrameLevel(4)
|
||||
icon.cooldown:SetFrameStrata(Gladdy.db.cooldownFrameStrata)
|
||||
icon.cooldown:SetFrameLevel(Gladdy.db.cooldownFrameLevel + 1)
|
||||
icon.cooldown:SetReverse(false)
|
||||
icon.cooldown:SetHideCountdownNumbers(true)
|
||||
|
||||
icon.cooldownFrame = CreateFrame("Frame", nil, icon)
|
||||
icon.cooldownFrame:ClearAllPoints()
|
||||
icon.cooldownFrame:SetAllPoints(icon)
|
||||
icon.cooldownFrame:SetFrameLevel(5)
|
||||
icon.cooldownFrame:SetFrameStrata(Gladdy.db.cooldownFrameStrata)
|
||||
icon.cooldownFrame:SetFrameLevel(Gladdy.db.cooldownFrameLevel + 2)
|
||||
|
||||
icon.border = icon.cooldownFrame:CreateTexture(nil, "OVERLAY")
|
||||
icon.border:SetAllPoints(icon)
|
||||
@ -136,6 +143,8 @@ function Cooldowns:UpdateFrame(unit)
|
||||
if (Gladdy.db.cooldown) then
|
||||
button.spellCooldownFrame:SetHeight(Gladdy.db.cooldownSize)
|
||||
button.spellCooldownFrame:SetWidth(1)
|
||||
button.spellCooldownFrame:SetFrameStrata(Gladdy.db.cooldownFrameStrata)
|
||||
button.spellCooldownFrame:SetFrameLevel(Gladdy.db.cooldownFrameLevel)
|
||||
button.spellCooldownFrame:Show()
|
||||
|
||||
Gladdy:SetPosition(button.spellCooldownFrame, unit, "cooldownXOffset", "cooldownYOffset", Cooldowns:LegacySetPosition(button, unit), Cooldowns)
|
||||
@ -149,6 +158,14 @@ function Cooldowns:UpdateFrame(unit)
|
||||
local o = 1
|
||||
for j = 1, 14 do
|
||||
local icon = button.spellCooldownFrame["icon" .. j]
|
||||
|
||||
icon:SetFrameStrata(Gladdy.db.cooldownFrameStrata)
|
||||
icon:SetFrameLevel(Gladdy.db.cooldownFrameLevel)
|
||||
icon.cooldown:SetFrameStrata(Gladdy.db.cooldownFrameStrata)
|
||||
icon.cooldown:SetFrameLevel(Gladdy.db.cooldownFrameLevel + 1)
|
||||
icon.cooldownFrame:SetFrameStrata(Gladdy.db.cooldownFrameStrata)
|
||||
icon.cooldownFrame:SetFrameLevel(Gladdy.db.cooldownFrameLevel + 2)
|
||||
|
||||
icon:SetHeight(Gladdy.db.cooldownSize)
|
||||
icon:SetWidth(Gladdy.db.cooldownSize * Gladdy.db.cooldownWidthFactor)
|
||||
icon.cooldownFont:SetFont(Gladdy:SMFetch("font", "cooldownFont"), Gladdy.db.cooldownSize / 2 * Gladdy.db.cooldownFontScale, "OUTLINE")
|
||||
@ -676,7 +693,7 @@ function Cooldowns:GetOptions()
|
||||
position = {
|
||||
type = "group",
|
||||
name = L["Position"],
|
||||
order = 4,
|
||||
order = 5,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
@ -740,7 +757,7 @@ function Cooldowns:GetOptions()
|
||||
border = {
|
||||
type = "group",
|
||||
name = L["Border"],
|
||||
order = 5,
|
||||
order = 4,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
@ -762,6 +779,35 @@ function Cooldowns:GetOptions()
|
||||
}),
|
||||
},
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 6,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
cooldownFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
cooldownFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 0,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
cooldowns = {
|
||||
|
@ -50,6 +50,8 @@ local Diminishings = Gladdy:NewModule("Diminishings", nil, {
|
||||
drWidthFactor = 1,
|
||||
drCategories = defaultCategories(),
|
||||
drDuration = 18,
|
||||
drFrameStrata = "MEDIUM",
|
||||
drFrameLevel = 3,
|
||||
})
|
||||
|
||||
local function getDiminishColor(dr)
|
||||
@ -81,12 +83,15 @@ function Diminishings:CreateFrame(unit)
|
||||
local drFrame = CreateFrame("Frame", nil, Gladdy.buttons[unit])
|
||||
drFrame:EnableMouse(false)
|
||||
drFrame:SetMovable(true)
|
||||
drFrame:SetFrameStrata(Gladdy.db.drFrameStrata)
|
||||
drFrame:SetFrameLevel(Gladdy.db.drFrameLevel)
|
||||
|
||||
for i = 1, 16 do
|
||||
local icon = CreateFrame("Frame", "GladdyDr" .. unit .. "Icon" .. i, drFrame)
|
||||
icon:Hide()
|
||||
icon:EnableMouse(false)
|
||||
icon:SetFrameLevel(3)
|
||||
icon:SetFrameStrata(Gladdy.db.drFrameStrata)
|
||||
icon:SetFrameLevel(Gladdy.db.drFrameLevel)
|
||||
icon.texture = icon:CreateTexture(nil, "BACKGROUND")
|
||||
icon.texture:SetMask("Interface\\AddOns\\Gladdy\\Images\\mask")
|
||||
icon.texture:SetAllPoints(icon)
|
||||
@ -114,13 +119,15 @@ function Diminishings:CreateFrame(unit)
|
||||
icon.cooldown = CreateFrame("Cooldown", nil, icon, "CooldownFrameTemplate")
|
||||
icon.cooldown.noCooldownCount = true --Gladdy.db.trinketDisableOmniCC
|
||||
icon.cooldown:SetHideCountdownNumbers(true)
|
||||
icon.cooldown:SetFrameLevel(4)
|
||||
icon.cooldown:SetFrameStrata(Gladdy.db.drFrameStrata)
|
||||
icon.cooldown:SetFrameLevel(Gladdy.db.drFrameLevel + 1)
|
||||
|
||||
icon.cooldownFrame = CreateFrame("Frame", nil, icon)
|
||||
icon.cooldownFrame:ClearAllPoints()
|
||||
icon.cooldownFrame:SetPoint("TOPLEFT", icon, "TOPLEFT")
|
||||
icon.cooldownFrame:SetPoint("BOTTOMRIGHT", icon, "BOTTOMRIGHT")
|
||||
icon.cooldownFrame:SetFrameLevel(5)
|
||||
icon.cooldownFrame:SetFrameStrata(Gladdy.db.drFrameStrata)
|
||||
icon.cooldownFrame:SetFrameLevel(Gladdy.db.drFrameLevel + 2)
|
||||
|
||||
--icon.overlay = CreateFrame("Frame", nil, icon)
|
||||
--icon.overlay:SetAllPoints(icon)
|
||||
@ -181,6 +188,8 @@ function Diminishings:UpdateFrame(unit)
|
||||
|
||||
drFrame:SetWidth(Gladdy.db.drIconSize)
|
||||
drFrame:SetHeight(Gladdy.db.drIconSize)
|
||||
drFrame:SetFrameStrata(Gladdy.db.drFrameStrata)
|
||||
drFrame:SetFrameLevel(Gladdy.db.drFrameLevel)
|
||||
|
||||
Gladdy:SetPosition(drFrame, unit, "drXOffset", "drYOffset", Diminishings:LegacySetPosition(drFrame, unit), Diminishings)
|
||||
|
||||
@ -199,6 +208,13 @@ function Diminishings:UpdateFrame(unit)
|
||||
icon:SetWidth(Gladdy.db.drIconSize * Gladdy.db.drWidthFactor)
|
||||
icon:SetHeight(Gladdy.db.drIconSize)
|
||||
|
||||
icon:SetFrameStrata(Gladdy.db.drFrameStrata)
|
||||
icon:SetFrameLevel(Gladdy.db.drFrameLevel)
|
||||
icon.cooldown:SetFrameStrata(Gladdy.db.drFrameStrata)
|
||||
icon.cooldown:SetFrameLevel(Gladdy.db.drFrameLevel + 1)
|
||||
icon.cooldownFrame:SetFrameStrata(Gladdy.db.drFrameStrata)
|
||||
icon.cooldownFrame:SetFrameLevel(Gladdy.db.drFrameLevel + 2)
|
||||
|
||||
icon.text:SetFont(Gladdy:SMFetch("font", "drFont"), (Gladdy.db.drIconSize/2 - 1) * Gladdy.db.drFontScale, "OUTLINE")
|
||||
icon.text:SetTextColor(Gladdy.db.drFontColor.r, Gladdy.db.drFontColor.g, Gladdy.db.drFontColor.b, Gladdy.db.drFontColor.a)
|
||||
icon.timeText:SetFont(Gladdy:SMFetch("font", "drFont"), (Gladdy.db.drIconSize/2 - 1) * Gladdy.db.drFontScale, "OUTLINE")
|
||||
@ -541,7 +557,7 @@ function Diminishings:GetOptions()
|
||||
position = {
|
||||
type = "group",
|
||||
name = L["Position"],
|
||||
order = 4,
|
||||
order = 6,
|
||||
args = {
|
||||
headerPosition = {
|
||||
type = "header",
|
||||
@ -618,7 +634,7 @@ function Diminishings:GetOptions()
|
||||
border = {
|
||||
type = "group",
|
||||
name = L["Border"],
|
||||
order = 6,
|
||||
order = 4,
|
||||
args = {
|
||||
headerBorder = {
|
||||
type = "header",
|
||||
@ -673,6 +689,35 @@ function Diminishings:GetOptions()
|
||||
}),
|
||||
}
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 7,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
drFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
drFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 0,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
categories = {
|
||||
|
@ -24,6 +24,8 @@ local Healthbar = Gladdy:NewModule("Health Bar", 100, {
|
||||
healthActual = false,
|
||||
healthMax = true,
|
||||
healthPercentage = true,
|
||||
healthFrameStrata = "MEDIUM",
|
||||
healthFrameLevel = 1,
|
||||
})
|
||||
|
||||
function Healthbar:Initialize()
|
||||
@ -42,12 +44,14 @@ function Healthbar:CreateFrame(unit)
|
||||
healthBar:SetBackdrop({ edgeFile = Gladdy:SMFetch("border", "healthBarBorderStyle"),
|
||||
edgeSize = Gladdy.db.healthBarBorderSize })
|
||||
healthBar:SetBackdropBorderColor(Gladdy.db.healthBarBorderColor.r, Gladdy.db.healthBarBorderColor.g, Gladdy.db.healthBarBorderColor.b, Gladdy.db.healthBarBorderColor.a)
|
||||
healthBar:SetFrameLevel(1)
|
||||
healthBar:SetFrameStrata(Gladdy.db.healthFrameStrata)
|
||||
healthBar:SetFrameLevel(Gladdy.db.healthFrameLevel)
|
||||
|
||||
healthBar.hp = CreateFrame("StatusBar", nil, healthBar)
|
||||
healthBar.hp:SetStatusBarTexture(Gladdy:SMFetch("statusbar", "healthBarTexture"))
|
||||
healthBar.hp:SetMinMaxValues(0, 100)
|
||||
healthBar.hp:SetFrameLevel(0)
|
||||
healthBar.hp:SetFrameStrata(Gladdy.db.healthFrameStrata)
|
||||
healthBar.hp:SetFrameLevel(Gladdy.db.healthFrameLevel - 1)
|
||||
|
||||
healthBar.bg = healthBar.hp:CreateTexture(nil, "BACKGROUND")
|
||||
healthBar.bg:SetTexture(Gladdy:SMFetch("statusbar", "healthBarTexture"))
|
||||
@ -150,6 +154,11 @@ function Healthbar:UpdateFrame(unit)
|
||||
return
|
||||
end
|
||||
|
||||
healthBar:SetFrameStrata(Gladdy.db.healthFrameStrata)
|
||||
healthBar:SetFrameLevel(Gladdy.db.healthFrameLevel)
|
||||
healthBar.hp:SetFrameStrata(Gladdy.db.healthFrameStrata)
|
||||
healthBar.hp:SetFrameLevel(Gladdy.db.healthFrameLevel - 1)
|
||||
|
||||
healthBar.bg:SetTexture(Gladdy:SMFetch("statusbar", "healthBarTexture"))
|
||||
healthBar.bg:SetVertexColor(Gladdy.db.healthBarBgColor.r, Gladdy.db.healthBarBgColor.g, Gladdy.db.healthBarBgColor.b, Gladdy.db.healthBarBgColor.a)
|
||||
|
||||
@ -445,10 +454,39 @@ function Healthbar:GetOptions()
|
||||
}),
|
||||
},
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 4,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
healthFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
healthFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 1,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
healthValues = {
|
||||
type = "group",
|
||||
name = L["Health Bar Text"],
|
||||
order = 4,
|
||||
order = 5,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
|
@ -13,6 +13,8 @@ local Highlight = Gladdy:NewModule("Highlight", nil, {
|
||||
targetBorder = true,
|
||||
focusBorder = true,
|
||||
leaderBorder = true,
|
||||
highlightFrameStrata = "MEDIUM",
|
||||
highlightFrameLevel = 20,
|
||||
})
|
||||
|
||||
function Highlight:Initialize()
|
||||
@ -56,17 +58,20 @@ function Highlight:CreateFrame(unit)
|
||||
|
||||
local targetBorder = CreateFrame("Frame", nil, button, BackdropTemplateMixin and "BackdropTemplate")
|
||||
targetBorder:SetBackdrop({ edgeFile = Gladdy:SMFetch("border", "highlightBorderStyle"), edgeSize = Gladdy.db.highlightBorderSize })
|
||||
--targetBorder:SetFrameStrata("MEDIUM")
|
||||
targetBorder:SetFrameStrata(Gladdy.db.highlightFrameStrata)
|
||||
targetBorder:SetFrameLevel(Gladdy.db.highlightFrameLevel)
|
||||
targetBorder:Hide()
|
||||
|
||||
local focusBorder = CreateFrame("Frame", nil, button, BackdropTemplateMixin and "BackdropTemplate")
|
||||
focusBorder:SetBackdrop({ edgeFile = Gladdy:SMFetch("border", "highlightBorderStyle"), edgeSize = Gladdy.db.highlightBorderSize })
|
||||
--focusBorder:SetFrameStrata("MEDIUM")
|
||||
focusBorder:SetFrameStrata(Gladdy.db.highlightFrameStrata)
|
||||
focusBorder:SetFrameLevel(Gladdy.db.highlightFrameLevel)
|
||||
focusBorder:Hide()
|
||||
|
||||
local leaderBorder = CreateFrame("Frame", nil, button, BackdropTemplateMixin and "BackdropTemplate")
|
||||
leaderBorder:SetBackdrop({ edgeFile = Gladdy:SMFetch("border", "highlightBorderStyle"), edgeSize = Gladdy.db.highlightBorderSize })
|
||||
--leaderBorder:SetFrameStrata("MEDIUM")
|
||||
leaderBorder:SetFrameStrata(Gladdy.db.highlightFrameStrata)
|
||||
leaderBorder:SetFrameLevel(Gladdy.db.highlightFrameLevel)
|
||||
leaderBorder:Hide()
|
||||
|
||||
local highlight = healthBar:CreateTexture(nil, "OVERLAY")
|
||||
@ -96,6 +101,13 @@ function Highlight:UpdateFrame(unit)
|
||||
local width = Gladdy.db.barWidth + (Gladdy.db.highlightInset and 0 or borderSize * 2)
|
||||
local height = hpAndPowerHeight + (Gladdy.db.highlightInset and 0 or borderSize * 2)
|
||||
|
||||
button.targetBorder:SetFrameStrata(Gladdy.db.highlightFrameStrata)
|
||||
button.targetBorder:SetFrameLevel(Gladdy.db.highlightFrameLevel)
|
||||
button.focusBorder:SetFrameStrata(Gladdy.db.highlightFrameStrata)
|
||||
button.focusBorder:SetFrameLevel(Gladdy.db.highlightFrameLevel)
|
||||
button.leaderBorder:SetFrameStrata(Gladdy.db.highlightFrameStrata)
|
||||
button.leaderBorder:SetFrameLevel(Gladdy.db.highlightFrameLevel)
|
||||
|
||||
button.targetBorder:SetWidth(width)
|
||||
button.targetBorder:SetHeight(height)
|
||||
button.targetBorder:ClearAllPoints()
|
||||
@ -207,67 +219,130 @@ function Highlight:GetOptions()
|
||||
desc = L["Show Highlight border inside of frame"],
|
||||
order = 3,
|
||||
}),
|
||||
highlightBorderSize = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Border size"],
|
||||
desc = L["Border size"],
|
||||
order = 4,
|
||||
min = 1,
|
||||
max = 20,
|
||||
step = 1,
|
||||
width = "full",
|
||||
}),
|
||||
highlightBorderStyle = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Border style"],
|
||||
order = 5,
|
||||
dialogControl = "LSM30_Border",
|
||||
values = AceGUIWidgetLSMlists.border,
|
||||
}),
|
||||
headerColor = {
|
||||
type = "header",
|
||||
name = L["Colors"],
|
||||
order = 6,
|
||||
group = {
|
||||
type = "group",
|
||||
childGroups = "tree",
|
||||
name = L["Frame"],
|
||||
order = 3,
|
||||
args = {
|
||||
enabled = {
|
||||
type = "group",
|
||||
name = L["Enabled"],
|
||||
order = 1,
|
||||
args = {
|
||||
headerEnable = {
|
||||
type = "header",
|
||||
name = L["Enabled"],
|
||||
order = 10,
|
||||
},
|
||||
highlight = Gladdy:option({
|
||||
type = "toggle",
|
||||
name = L["Highlight target"],
|
||||
desc = L["Toggle if the selected target should be highlighted"],
|
||||
order = 11,
|
||||
width = "full",
|
||||
}),
|
||||
targetBorder = Gladdy:option({
|
||||
type = "toggle",
|
||||
name = L["Show border around target"],
|
||||
desc = L["Toggle if a border should be shown around the selected target"],
|
||||
order = 12,
|
||||
width = "full",
|
||||
}),
|
||||
focusBorder = Gladdy:option({
|
||||
type = "toggle",
|
||||
name = L["Show border around focus"],
|
||||
desc = L["Toggle of a border should be shown around the current focus"],
|
||||
order = 13,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
border = {
|
||||
type = "group",
|
||||
name = L["Border"],
|
||||
order = 2,
|
||||
args = {
|
||||
headerHighlight = {
|
||||
type = "header",
|
||||
name = L["Border"],
|
||||
order = 2,
|
||||
},
|
||||
highlightBorderSize = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Border size"],
|
||||
desc = L["Border size"],
|
||||
order = 4,
|
||||
min = 1,
|
||||
max = 20,
|
||||
step = 1,
|
||||
width = "full",
|
||||
}),
|
||||
highlightBorderStyle = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Border style"],
|
||||
order = 5,
|
||||
dialogControl = "LSM30_Border",
|
||||
values = AceGUIWidgetLSMlists.border,
|
||||
}),
|
||||
},
|
||||
},
|
||||
color = {
|
||||
type = "group",
|
||||
name = L["Color"],
|
||||
order = 3,
|
||||
args = {
|
||||
headerColor = {
|
||||
type = "header",
|
||||
name = L["Colors"],
|
||||
order = 6,
|
||||
},
|
||||
targetBorderColor = Gladdy:colorOption({
|
||||
type = "color",
|
||||
name = L["Target border color"],
|
||||
desc = L["Color of the selected targets border"],
|
||||
order = 7,
|
||||
hasAlpha = true,
|
||||
}),
|
||||
focusBorderColor = Gladdy:colorOption({
|
||||
type = "color",
|
||||
name = L["Focus border color"],
|
||||
desc = L["Color of the focus border"],
|
||||
order = 8,
|
||||
hasAlpha = true,
|
||||
}),
|
||||
},
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 4,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
highlightFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
highlightFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 1,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
targetBorderColor = Gladdy:colorOption({
|
||||
type = "color",
|
||||
name = L["Target border color"],
|
||||
desc = L["Color of the selected targets border"],
|
||||
order = 7,
|
||||
hasAlpha = true,
|
||||
}),
|
||||
focusBorderColor = Gladdy:colorOption({
|
||||
type = "color",
|
||||
name = L["Focus border color"],
|
||||
desc = L["Color of the focus border"],
|
||||
order = 8,
|
||||
hasAlpha = true,
|
||||
}),
|
||||
headerEnable = {
|
||||
type = "header",
|
||||
name = L["Enabled"],
|
||||
order = 10,
|
||||
},
|
||||
highlight = Gladdy:option({
|
||||
type = "toggle",
|
||||
name = L["Highlight target"],
|
||||
desc = L["Toggle if the selected target should be highlighted"],
|
||||
order = 11,
|
||||
width = "full",
|
||||
}),
|
||||
targetBorder = Gladdy:option({
|
||||
type = "toggle",
|
||||
name = L["Show border around target"],
|
||||
desc = L["Toggle if a border should be shown around the selected target"],
|
||||
order = 12,
|
||||
width = "full",
|
||||
}),
|
||||
focusBorder = Gladdy:option({
|
||||
type = "toggle",
|
||||
name = L["Show border around focus"],
|
||||
desc = L["Toggle of a border should be shown around the current focus"],
|
||||
order = 13,
|
||||
width = "full",
|
||||
}),
|
||||
}
|
||||
end
|
@ -25,6 +25,8 @@ local Pets = Gladdy:NewModule("Pets", nil, {
|
||||
petYOffset = -62,
|
||||
petGroup = false,
|
||||
petMargin = 1,
|
||||
petFrameStrata = "MEDIUM",
|
||||
petFrameLevel = 5,
|
||||
})
|
||||
|
||||
function Pets:Initialize()
|
||||
@ -156,7 +158,8 @@ function Pets:CreateFrame(unitId)
|
||||
healthBar:SetBackdrop({ edgeFile = Gladdy:SMFetch("border", "petHealthBarBorderStyle"),
|
||||
edgeSize = Gladdy.db.petHealthBarBorderSize })
|
||||
healthBar:SetBackdropBorderColor(Gladdy.db.petHealthBarBorderColor.r, Gladdy.db.petHealthBarBorderColor.g, Gladdy.db.petHealthBarBorderColor.b, Gladdy.db.petHealthBarBorderColor.a)
|
||||
healthBar:SetFrameLevel(1)
|
||||
healthBar:SetFrameStrata(Gladdy.db.petFrameStrata)
|
||||
healthBar:SetFrameLevel(Gladdy.db.petFrameLevel)
|
||||
healthBar:SetAllPoints(button)
|
||||
healthBar:SetAlpha(0)
|
||||
|
||||
@ -174,7 +177,8 @@ function Pets:CreateFrame(unitId)
|
||||
healthBar.hp:SetStatusBarTexture(Gladdy:SMFetch("statusbar", "petHealthBarTexture"))
|
||||
healthBar.hp:SetStatusBarColor(Gladdy.db.petHealthBarColor.r, Gladdy.db.petHealthBarColor.g, Gladdy.db.petHealthBarColor.b, Gladdy.db.petHealthBarColor.a)
|
||||
healthBar.hp:SetMinMaxValues(0, 100)
|
||||
healthBar.hp:SetFrameLevel(0)
|
||||
healthBar.hp:SetFrameStrata(Gladdy.db.petFrameStrata)
|
||||
healthBar.hp:SetFrameLevel(Gladdy.db.petFrameLevel - 1)
|
||||
healthBar.hp:SetAllPoints(healthBar)
|
||||
|
||||
healthBar.bg = healthBar.hp:CreateTexture(nil, "BACKGROUND")
|
||||
@ -245,6 +249,11 @@ function Pets:UpdateFrame(unitId)
|
||||
return
|
||||
end
|
||||
|
||||
healthBar:SetFrameStrata(Gladdy.db.petFrameStrata)
|
||||
healthBar:SetFrameLevel(Gladdy.db.petFrameLevel)
|
||||
healthBar.hp:SetFrameStrata(Gladdy.db.petFrameStrata)
|
||||
healthBar.hp:SetFrameLevel(Gladdy.db.petFrameLevel - 1)
|
||||
|
||||
if not Gladdy.db.petEnabled then
|
||||
self.frames[unit]:Hide()
|
||||
else
|
||||
@ -569,10 +578,39 @@ function Pets:GetOptions()
|
||||
}),
|
||||
}
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 6,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
petFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
petFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 1,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
healthValues = {
|
||||
type = "group",
|
||||
name = L["Health Values"],
|
||||
order = 6,
|
||||
order = 7,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
|
@ -22,6 +22,8 @@ local Powerbar = Gladdy:NewModule("Power Bar", 90, {
|
||||
powerActual = true,
|
||||
powerMax = true,
|
||||
powerPercentage = false,
|
||||
powerFrameStrata = "MEDIUM",
|
||||
powerFrameLevel = 1,
|
||||
})
|
||||
|
||||
function Powerbar:Initialize()
|
||||
@ -41,12 +43,14 @@ function Powerbar:CreateFrame(unit)
|
||||
powerBar:SetBackdrop({ edgeFile = Gladdy:SMFetch("border", "powerBarBorderStyle"),
|
||||
edgeSize = Gladdy.db.powerBarBorderSize })
|
||||
powerBar:SetBackdropBorderColor(Gladdy.db.powerBarBorderColor.r, Gladdy.db.powerBarBorderColor.g, Gladdy.db.powerBarBorderColor.b, Gladdy.db.powerBarBorderColor.a)
|
||||
powerBar:SetFrameLevel(1)
|
||||
powerBar:SetFrameStrata(Gladdy.db.powerFrameStrata)
|
||||
powerBar:SetFrameLevel(Gladdy.db.powerFrameLevel)
|
||||
|
||||
powerBar.energy = CreateFrame("StatusBar", nil, powerBar)
|
||||
powerBar.energy:SetStatusBarTexture(Gladdy:SMFetch("statusbar", "powerBarTexture"))
|
||||
powerBar.energy:SetMinMaxValues(0, 100)
|
||||
powerBar.energy:SetFrameLevel(0)
|
||||
powerBar.energy:SetFrameStrata(Gladdy.db.powerFrameStrata)
|
||||
powerBar.energy:SetFrameLevel(Gladdy.db.powerFrameLevel - 1)
|
||||
|
||||
powerBar.bg = powerBar.energy:CreateTexture(nil, "BACKGROUND")
|
||||
powerBar.bg:SetTexture(Gladdy:SMFetch("statusbar", "powerBarTexture"))
|
||||
@ -139,10 +143,8 @@ function Powerbar:UpdateFrame(unit)
|
||||
if (not powerBar) then
|
||||
return
|
||||
end
|
||||
|
||||
local healthBar = Gladdy.modules["Health Bar"].frames[unit]
|
||||
|
||||
|
||||
if not Gladdy.db.powerBarEnabled then
|
||||
powerBar:Hide()
|
||||
return
|
||||
@ -171,6 +173,11 @@ function Powerbar:UpdateFrame(unit)
|
||||
powerBar.raceText:SetTextColor(Gladdy.db.powerBarFontColor.r, Gladdy.db.powerBarFontColor.g, Gladdy.db.powerBarFontColor.b, Gladdy.db.powerBarFontColor.a)
|
||||
powerBar.powerText:SetFont(Gladdy:SMFetch("font", "powerBarFont"), Gladdy.db.powerBarFontSize)
|
||||
powerBar.powerText:SetTextColor(Gladdy.db.powerBarFontColor.r, Gladdy.db.powerBarFontColor.g, Gladdy.db.powerBarFontColor.b, Gladdy.db.powerBarFontColor.a)
|
||||
|
||||
powerBar:SetFrameStrata(Gladdy.db.powerFrameStrata)
|
||||
powerBar:SetFrameLevel(Gladdy.db.powerFrameLevel)
|
||||
powerBar.energy:SetFrameStrata(Gladdy.db.powerFrameStrata)
|
||||
powerBar.energy:SetFrameLevel(Gladdy.db.powerFrameLevel - 1)
|
||||
end
|
||||
|
||||
function Powerbar:ResetUnit(unit)
|
||||
@ -455,10 +462,39 @@ function Powerbar:GetOptions()
|
||||
}),
|
||||
},
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 4,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
powerFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
powerFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 1,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
powerValues = {
|
||||
type = "group",
|
||||
name = L["Power Bar Text"],
|
||||
order = 4,
|
||||
order = 5,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
|
@ -18,6 +18,8 @@ local Racial = Gladdy:NewModule("Racial", 79, {
|
||||
racialDisableCircle = false,
|
||||
racialCooldownAlpha = 1,
|
||||
racialCooldownNumberAlpha = 1,
|
||||
racialFrameStrata = "MEDIUM",
|
||||
racialFrameLevel = 5,
|
||||
})
|
||||
|
||||
|
||||
@ -63,6 +65,9 @@ end
|
||||
function Racial:CreateFrame(unit)
|
||||
local racial = CreateFrame("Button", "GladdyTrinketButton" .. unit, Gladdy.buttons[unit])
|
||||
racial:EnableMouse(false)
|
||||
racial:SetFrameStrata(Gladdy.db.racialFrameStrata)
|
||||
racial:SetFrameLevel(Gladdy.db.racialFrameLevel)
|
||||
|
||||
racial.texture = racial:CreateTexture(nil, "BACKGROUND")
|
||||
racial.texture:SetAllPoints(racial)
|
||||
racial.texture:SetMask("Interface\\AddOns\\Gladdy\\Images\\mask")
|
||||
@ -76,6 +81,8 @@ function Racial:CreateFrame(unit)
|
||||
racial.cooldownFrame:ClearAllPoints()
|
||||
racial.cooldownFrame:SetPoint("TOPLEFT", racial, "TOPLEFT")
|
||||
racial.cooldownFrame:SetPoint("BOTTOMRIGHT", racial, "BOTTOMRIGHT")
|
||||
racial.cooldownFrame:SetFrameStrata(Gladdy.db.racialFrameStrata)
|
||||
racial.cooldownFrame:SetFrameLevel(Gladdy.db.racialFrameLevel + 1)
|
||||
|
||||
racial.cooldownFont = racial.cooldownFrame:CreateFontString(nil, "OVERLAY")
|
||||
racial.cooldownFont:SetFont(Gladdy:SMFetch("font", "racialFont"), 20, "OUTLINE")
|
||||
@ -85,6 +92,9 @@ function Racial:CreateFrame(unit)
|
||||
|
||||
racial.borderFrame = CreateFrame("Frame", nil, racial)
|
||||
racial.borderFrame:SetAllPoints(racial)
|
||||
racial.borderFrame:SetFrameStrata(Gladdy.db.racialFrameStrata)
|
||||
racial.borderFrame:SetFrameLevel(Gladdy.db.racialFrameLevel + 2)
|
||||
|
||||
racial.texture.overlay = racial.borderFrame:CreateTexture(nil, "OVERLAY")
|
||||
racial.texture.overlay:SetAllPoints(racial)
|
||||
racial.texture.overlay:SetTexture(Gladdy.db.racialBorderStyle)
|
||||
@ -103,6 +113,13 @@ function Racial:UpdateFrame(unit)
|
||||
|
||||
local width, height = Gladdy.db.racialSize * Gladdy.db.racialWidthFactor, Gladdy.db.racialSize
|
||||
|
||||
racial:SetFrameStrata(Gladdy.db.racialFrameStrata)
|
||||
racial:SetFrameLevel(Gladdy.db.racialFrameLevel)
|
||||
racial.cooldownFrame:SetFrameStrata(Gladdy.db.racialFrameStrata)
|
||||
racial.cooldownFrame:SetFrameLevel(Gladdy.db.racialFrameLevel + 1)
|
||||
racial.borderFrame:SetFrameStrata(Gladdy.db.racialFrameStrata)
|
||||
racial.borderFrame:SetFrameLevel(Gladdy.db.racialFrameLevel + 2)
|
||||
|
||||
racial:SetWidth(width)
|
||||
racial:SetHeight(height)
|
||||
racial.cooldown:SetWidth(width - width/16)
|
||||
@ -311,37 +328,13 @@ function Racial:GetOptions()
|
||||
position = {
|
||||
type = "group",
|
||||
name = L["Position"],
|
||||
order = 4,
|
||||
order = 5,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
name = L["Icon position"],
|
||||
order = 4,
|
||||
},
|
||||
racialAnchor = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Anchor"],
|
||||
desc = L["This changes the anchor of the racial icon"],
|
||||
order = 20,
|
||||
values = {
|
||||
["trinket"] = L["Trinket"],
|
||||
["classIcon"] = L["Class Icon"],
|
||||
["healthBar"] = L["Health Bar"],
|
||||
["powerBar"] = L["Power Bar"],
|
||||
},
|
||||
}),
|
||||
racialPos = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Icon position"],
|
||||
desc = L["This changes position relative to its anchor of the racial icon"],
|
||||
order = 21,
|
||||
values = {
|
||||
["LEFT"] = L["Left"],
|
||||
["RIGHT"] = L["Right"],
|
||||
["TOP"] = L["Top"],
|
||||
["BOTTOM"] = L["Bottom"],
|
||||
},
|
||||
}),
|
||||
racialXOffset = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Horizontal offset"],
|
||||
@ -387,6 +380,35 @@ function Racial:GetOptions()
|
||||
}),
|
||||
},
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 6,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
racialFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
racialFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 0,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
@ -21,6 +21,8 @@ local ShadowsightTimer = Gladdy:NewModule("Shadowsight Timer", nil, {
|
||||
shadowsightTimerStartTime = 91,
|
||||
shadowsightTimerResetTime = 120,
|
||||
shadowsightTimerShowTwoTimer = false,
|
||||
shadowsightTimerFrameStrata = "HIGH",
|
||||
shadowsightTimerFrameLevel = 20,
|
||||
})
|
||||
|
||||
-- /run LibStub("Gladdy").modules["Shadowsight Timer"]:AURA_GAIN(nil, nil, 34709)
|
||||
@ -78,6 +80,9 @@ function ShadowsightTimer:CreateTimerFrame(anchor, name, points)
|
||||
self[name].font:SetPoint("LEFT", 5, 0)
|
||||
self[name].font:SetJustifyH("LEFT")
|
||||
self[name].font:SetTextColor(1, 0.8, 0)
|
||||
|
||||
self[name]:SetFrameStrata(Gladdy.db.shadowsightTimerFrameStrata)
|
||||
self[name]:SetFrameLevel(Gladdy.db.shadowsightTimerFrameLevel)
|
||||
end
|
||||
|
||||
function ShadowsightTimer:CreateAnchor()
|
||||
@ -102,6 +107,14 @@ end
|
||||
|
||||
function ShadowsightTimer:UpdateFrameOnce()
|
||||
self.anchor:EnableMouse(not Gladdy.db.shadowsightTimerLocked)
|
||||
|
||||
self.anchor:SetFrameStrata(Gladdy.db.shadowsightTimerFrameStrata)
|
||||
self.anchor:SetFrameLevel(Gladdy.db.shadowsightTimerFrameLevel)
|
||||
self.timerFrame1:SetFrameStrata(Gladdy.db.shadowsightTimerFrameStrata)
|
||||
self.timerFrame1:SetFrameLevel(Gladdy.db.shadowsightTimerFrameLevel)
|
||||
self.timerFrame2:SetFrameStrata(Gladdy.db.shadowsightTimerFrameStrata)
|
||||
self.timerFrame2:SetFrameLevel(Gladdy.db.shadowsightTimerFrameLevel)
|
||||
|
||||
if Gladdy.db.shadowsightTimerEnabled then
|
||||
self.anchor:SetScale(Gladdy.db.shadowsightTimerScale)
|
||||
self.anchor:ClearAllPoints()
|
||||
@ -268,7 +281,7 @@ end
|
||||
|
||||
function ShadowsightTimer:GetOptions()
|
||||
return {
|
||||
headerArenaCountdown = {
|
||||
headerShadowsight = {
|
||||
type = "header",
|
||||
name = L["Shadowsight Timer"],
|
||||
order = 2,
|
||||
@ -278,61 +291,143 @@ function ShadowsightTimer:GetOptions()
|
||||
name = L["Enabled"],
|
||||
--desc = L["Turns countdown before the start of an arena match on/off."],
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
shadowsightTimerLocked = Gladdy:option({
|
||||
type = "toggle",
|
||||
name = L["Locked"],
|
||||
--desc = L["Turns countdown before the start of an arena match on/off."],
|
||||
order = 4,
|
||||
width = "full",
|
||||
}),
|
||||
shadowsightTimerShowTwoTimer = Gladdy:option({
|
||||
type = "toggle",
|
||||
name = L["Show two timers"],
|
||||
order = 5,
|
||||
width = "full",
|
||||
}),
|
||||
shadowsightAnnounce = Gladdy:option({
|
||||
type = "toggle",
|
||||
name = L["Announce"],
|
||||
--desc = L["Turns countdown before the start of an arena match on/off."],
|
||||
order = 6,
|
||||
width = "full",
|
||||
}),
|
||||
shadowsightTimerScale = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Scale"],
|
||||
group = {
|
||||
type = "group",
|
||||
childGroups = "tree",
|
||||
name = L["Frame"],
|
||||
order = 7,
|
||||
min = 0.1,
|
||||
max = 5,
|
||||
step = 0.1,
|
||||
width = "full",
|
||||
}),
|
||||
headerTimer = {
|
||||
type = "header",
|
||||
name = L["Shadowsight CDs"],
|
||||
order = 10,
|
||||
args = {
|
||||
general = {
|
||||
type = "group",
|
||||
name = L["Scale"],
|
||||
order = 1,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
name = L["Scale"],
|
||||
order = 1,
|
||||
},
|
||||
shadowsightTimerScale = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Scale"],
|
||||
order = 2,
|
||||
min = 0.1,
|
||||
max = 5,
|
||||
step = 0.1,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
cooldown = {
|
||||
type = "group",
|
||||
name = L["Cooldown"],
|
||||
order = 2,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
name = L["Shadowsight CDs"],
|
||||
order = 1,
|
||||
},
|
||||
shadowsightTimerStartTime = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Start Time"],
|
||||
desc = L["Start time in seconds"],
|
||||
min = 80,
|
||||
max = 100,
|
||||
order = 2,
|
||||
step = 0.1,
|
||||
width = "full",
|
||||
}),
|
||||
shadowsightTimerResetTime = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Reset Time"],
|
||||
desc = L["Reset time in seconds"],
|
||||
min = 110,
|
||||
max = 130,
|
||||
order = 3,
|
||||
step = 0.1,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
--[[font = {
|
||||
type = "group",
|
||||
name = L["Font"],
|
||||
order = 3,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
name = L["Font"],
|
||||
order = 4,
|
||||
},
|
||||
racialFont = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Font"],
|
||||
desc = L["Font of the cooldown"],
|
||||
order = 11,
|
||||
dialogControl = "LSM30_Font",
|
||||
values = AceGUIWidgetLSMlists.font,
|
||||
}),
|
||||
racialFontScale = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Font scale"],
|
||||
desc = L["Scale of the font"],
|
||||
order = 12,
|
||||
min = 0.1,
|
||||
max = 2,
|
||||
step = 0.1,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},--]]
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 6,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
shadowsightTimerFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
shadowsightTimerFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 0,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
shadowsightTimerStartTime = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Start Time"],
|
||||
desc = L["Start time in seconds"],
|
||||
min = 80,
|
||||
max = 100,
|
||||
order = 11,
|
||||
step = 0.1,
|
||||
width = "full",
|
||||
}),
|
||||
shadowsightTimerResetTime = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Reset Time"],
|
||||
desc = L["Reset time in seconds"],
|
||||
min = 110,
|
||||
max = 130,
|
||||
order = 12,
|
||||
step = 0.1,
|
||||
width = "full",
|
||||
}),
|
||||
}
|
||||
end
|
@ -19,6 +19,8 @@ local Trinket = Gladdy:NewModule("Trinket", 80, {
|
||||
trinketCooldownNumberAlpha = 1,
|
||||
trinketXOffset = 0,
|
||||
trinketYOffset = 0,
|
||||
trinketFrameStrata = "MEDIUM",
|
||||
trinketFrameLevel = 5,
|
||||
})
|
||||
|
||||
function Trinket:Initialize()
|
||||
@ -62,6 +64,9 @@ end
|
||||
function Trinket:CreateFrame(unit)
|
||||
local trinket = CreateFrame("Button", "GladdyTrinketButton" .. unit, Gladdy.buttons[unit])
|
||||
trinket:EnableMouse(false)
|
||||
trinket:SetFrameStrata(Gladdy.db.trinketFrameStrata)
|
||||
trinket:SetFrameLevel(Gladdy.db.trinketFrameLevel)
|
||||
|
||||
trinket.texture = trinket:CreateTexture(nil, "BACKGROUND")
|
||||
trinket.texture:SetAllPoints(trinket)
|
||||
trinket.texture:SetTexture("Interface\\Icons\\INV_Jewelry_TrinketPVP_02")
|
||||
@ -70,11 +75,15 @@ function Trinket:CreateFrame(unit)
|
||||
trinket.cooldown = CreateFrame("Cooldown", nil, trinket, "CooldownFrameTemplate")
|
||||
trinket.cooldown.noCooldownCount = true --Gladdy.db.trinketDisableOmniCC
|
||||
trinket.cooldown:SetHideCountdownNumbers(true)
|
||||
trinket.cooldown:SetFrameStrata(Gladdy.db.trinketFrameStrata)
|
||||
trinket.cooldown:SetFrameLevel(Gladdy.db.trinketFrameLevel + 1)
|
||||
|
||||
trinket.cooldownFrame = CreateFrame("Frame", nil, trinket)
|
||||
trinket.cooldownFrame:ClearAllPoints()
|
||||
trinket.cooldownFrame:SetPoint("TOPLEFT", trinket, "TOPLEFT")
|
||||
trinket.cooldownFrame:SetPoint("BOTTOMRIGHT", trinket, "BOTTOMRIGHT")
|
||||
trinket.cooldownFrame:SetFrameStrata(Gladdy.db.trinketFrameStrata)
|
||||
trinket.cooldownFrame:SetFrameLevel(Gladdy.db.trinketFrameLevel + 2)
|
||||
|
||||
trinket.cooldownFont = trinket.cooldownFrame:CreateFontString(nil, "OVERLAY")
|
||||
trinket.cooldownFont:SetFont(Gladdy:SMFetch("font", "trinketFont"), 20, "OUTLINE")
|
||||
@ -84,6 +93,9 @@ function Trinket:CreateFrame(unit)
|
||||
|
||||
trinket.borderFrame = CreateFrame("Frame", nil, trinket)
|
||||
trinket.borderFrame:SetAllPoints(trinket)
|
||||
trinket.borderFrame:SetFrameStrata(Gladdy.db.trinketFrameStrata)
|
||||
trinket.borderFrame:SetFrameLevel(Gladdy.db.trinketFrameLevel + 3)
|
||||
|
||||
trinket.texture.overlay = trinket.borderFrame:CreateTexture(nil, "OVERLAY")
|
||||
trinket.texture.overlay:SetAllPoints(trinket)
|
||||
trinket.texture.overlay:SetTexture(Gladdy.db.trinketBorderStyle)
|
||||
@ -104,6 +116,15 @@ function Trinket:UpdateFrame(unit)
|
||||
|
||||
local width, height = Gladdy.db.trinketSize * Gladdy.db.trinketWidthFactor, Gladdy.db.trinketSize
|
||||
|
||||
trinket:SetFrameStrata(Gladdy.db.trinketFrameStrata)
|
||||
trinket:SetFrameLevel(Gladdy.db.trinketFrameLevel)
|
||||
trinket.cooldown:SetFrameStrata(Gladdy.db.trinketFrameStrata)
|
||||
trinket.cooldown:SetFrameLevel(Gladdy.db.trinketFrameLevel + 1)
|
||||
trinket.cooldownFrame:SetFrameStrata(Gladdy.db.trinketFrameStrata)
|
||||
trinket.cooldownFrame:SetFrameLevel(Gladdy.db.trinketFrameLevel + 2)
|
||||
trinket.borderFrame:SetFrameStrata(Gladdy.db.trinketFrameStrata)
|
||||
trinket.borderFrame:SetFrameLevel(Gladdy.db.trinketFrameLevel + 3)
|
||||
|
||||
trinket:SetWidth(width)
|
||||
trinket:SetHeight(height)
|
||||
trinket.cooldown:SetWidth(width - width/16)
|
||||
@ -316,22 +337,30 @@ function Trinket:GetOptions()
|
||||
position = {
|
||||
type = "group",
|
||||
name = L["Position"],
|
||||
order = 4,
|
||||
order = 5,
|
||||
args = {
|
||||
header = {
|
||||
type = "header",
|
||||
name = L["Icon position"],
|
||||
order = 4,
|
||||
},
|
||||
trinketPos = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Icon position"],
|
||||
desc = L["This changes positions of the trinket"],
|
||||
order = 21,
|
||||
values = {
|
||||
["LEFT"] = L["Left"],
|
||||
["RIGHT"] = L["Right"],
|
||||
},
|
||||
trinketXOffset = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Horizontal offset"],
|
||||
order = 23,
|
||||
min = -800,
|
||||
max = 800,
|
||||
step = 0.1,
|
||||
width = "full",
|
||||
}),
|
||||
trinketYOffset = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Vertical offset"],
|
||||
order = 24,
|
||||
min = -800,
|
||||
max = 800,
|
||||
step = 0.1,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
@ -360,6 +389,35 @@ function Trinket:GetOptions()
|
||||
}),
|
||||
},
|
||||
},
|
||||
frameStrata = {
|
||||
type = "group",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 6,
|
||||
args = {
|
||||
headerAuraLevel = {
|
||||
type = "header",
|
||||
name = L["Frame Strata and Level"],
|
||||
order = 1,
|
||||
},
|
||||
trinketFrameStrata = Gladdy:option({
|
||||
type = "select",
|
||||
name = L["Frame Strata"],
|
||||
order = 2,
|
||||
values = Gladdy.frameStrata,
|
||||
sorting = Gladdy.frameStrataSorting,
|
||||
width = "full",
|
||||
}),
|
||||
trinketFrameLevel = Gladdy:option({
|
||||
type = "range",
|
||||
name = L["Frame Level"],
|
||||
min = 0,
|
||||
max = 500,
|
||||
step = 1,
|
||||
order = 3,
|
||||
width = "full",
|
||||
}),
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user