fix #75 Remove AuraBars

Maybe in future will be added, but requires another load of work to add. Other things to tackle at the moment.
This commit is contained in:
Crum
2018-12-08 15:13:26 -06:00
parent 93f5762a44
commit 7cdaf21377
27 changed files with 14 additions and 1166 deletions
+3 -17
View File
@@ -237,7 +237,6 @@ function E:SetupTheme(theme, noDisplayMsg)
E.db.unitframe.colors.borderColor = (E.PixelMode and E:GetColor(0, 0, 0) or E:GetColor(.31, .31, .31))
E.db.unitframe.colors.healthclass = false
E.db.unitframe.colors.health = E:GetColor(.31, .31, .31)
E.db.unitframe.colors.auraBarBuff = E:GetColor(.31, .31, .31)
E.db.unitframe.colors.castColor = E:GetColor(.31, .31, .31)
E.db.unitframe.colors.castClassColor = false
elseif theme == "class" then
@@ -245,7 +244,6 @@ function E:SetupTheme(theme, noDisplayMsg)
E.db.general.backdropcolor = E:GetColor(.1, .1, .1)
E.db.general.backdropfadecolor = E:GetColor(.06, .06, .06, .8)
E.db.unitframe.colors.borderColor = (E.PixelMode and E:GetColor(0, 0, 0) or E:GetColor(.31, .31, .31))
E.db.unitframe.colors.auraBarBuff = E:GetColor(classColor.r, classColor.b, classColor.g)
E.db.unitframe.colors.healthclass = true
E.db.unitframe.colors.castClassColor = true
else
@@ -253,7 +251,6 @@ function E:SetupTheme(theme, noDisplayMsg)
E.db.general.backdropcolor = E:GetColor(.1, .1, .1)
E.db.general.backdropfadecolor = E:GetColor(.054, .054, .054, .8)
E.db.unitframe.colors.borderColor = (E.PixelMode and E:GetColor(0, 0, 0) or E:GetColor(.1, .1, .1))
E.db.unitframe.colors.auraBarBuff = E:GetColor(.1, .1, .1)
E.db.unitframe.colors.healthclass = false
E.db.unitframe.colors.health = E:GetColor(.1, .1, .1)
E.db.unitframe.colors.castColor = E:GetColor(.1, .1, .1)
@@ -643,34 +640,28 @@ local function SetupAuras(style)
local frame = UF.player
E:CopyTable(E.db.unitframe.units.player.buffs, P.unitframe.units.player.buffs)
E:CopyTable(E.db.unitframe.units.player.debuffs, P.unitframe.units.player.debuffs)
E:CopyTable(E.db.unitframe.units.player.aurabar, P.unitframe.units.player.aurabar)
if frame then
UF:Configure_Auras(frame, "Buffs")
UF:Configure_Auras(frame, "Debuffs")
-- UF:Configure_AuraBars(frame)
end
frame = UF.target
E:CopyTable(E.db.unitframe.units.target.buffs, P.unitframe.units.target.buffs)
E:CopyTable(E.db.unitframe.units.target.debuffs, P.unitframe.units.target.debuffs)
E:CopyTable(E.db.unitframe.units.target.aurabar, P.unitframe.units.target.aurabar)
if frame then
UF:Configure_Auras(frame, "Buffs")
UF:Configure_Auras(frame, "Debuffs")
-- UF:Configure_AuraBars(frame)
end
frame = UF.focus
E:CopyTable(E.db.unitframe.units.focus.buffs, P.unitframe.units.focus.buffs)
E:CopyTable(E.db.unitframe.units.focus.debuffs, P.unitframe.units.focus.debuffs)
E:CopyTable(E.db.unitframe.units.focus.aurabar, P.unitframe.units.focus.aurabar)
if frame then
UF:Configure_Auras(frame, "Buffs")
UF:Configure_Auras(frame, "Debuffs")
UF:Configure_AuraBars(frame)
end
if not style then
@@ -678,14 +669,12 @@ local function SetupAuras(style)
E.db.unitframe.units.player.buffs.enable = true
E.db.unitframe.units.player.buffs.attachTo = "FRAME"
E.db.unitframe.units.player.debuffs.attachTo = "BUFFS"
E.db.unitframe.units.player.aurabar.enable = false
if E.private.unitframe.enable then
E:GetModule("UnitFrames"):CreateAndUpdateUF("player")
end
--TARGET
E.db.unitframe.units.target.debuffs.enable = true
E.db.unitframe.units.target.aurabar.enable = false
if E.private.unitframe.enable then
E:GetModule("UnitFrames"):CreateAndUpdateUF("target")
end
@@ -831,14 +820,11 @@ local function SetPage(PageNum)
elseif PageNum == 7 then
f.SubTitle:SetText(L["Auras"])
f.Desc1:SetText(L["Select the type of aura system you want to use with ElvUI's unitframes. Set to Aura Bar & Icons to use both aura bars and icons, set to icons only to only see icons."])
f.Desc2:SetText(L["If you have an icon or aurabar that you don't want to display simply hold down shift and right click the icon for it to disapear."])
f.Desc2:SetText(L["If you have an icon that you don't want to display simply hold down shift and right click the icon for it to disapear."])
f.Desc3:SetText(L["Importance: |cffD3CF00Medium|r"])
InstallOption1Button:Show()
InstallOption1Button:SetScript("OnClick", function() --[[SetupAuras(true)--]] end)
InstallOption1Button:SetText(L["Aura Bars & Icons"])
InstallOption2Button:Show()
InstallOption2Button:SetScript("OnClick", function() --[[SetupAuras()--]] end)
InstallOption2Button:SetText(L["Icons Only"])
InstallOption1Button:SetScript("OnClick", function() SetupAuras() end)
InstallOption1Button:SetText(L["Icons Only"])
elseif PageNum == 8 then
f.SubTitle:SetText(L["Installation Complete"])
f.Desc1:SetText(L["You are now finished with the installation process. If you are in need of technical support please visit us at https://github.com/ElvUI-Vanilla/ElvUI"])
@@ -1,392 +0,0 @@
local ns = oUF
local oUF = ns.oUF
assert(oUF, "oUF_AuraBars was unable to locate oUF install.")
local format = string.format
local floor, huge, min, mod = math.floor, math.huge, math.min, math.mod
local tsort, getn = table.sort, table.getn
local tremove = table.remove
local random = math.random
local CreateFrame = CreateFrame
local UnitAura = UnitAura
local UnitIsFriend = UnitIsFriend
local DAY, HOUR, MINUTE = 86400, 3600, 60
local function FormatTime(s)
if s < MINUTE then
return format("%.1fs", s)
elseif s < HOUR then
return format("%dm %ds", mod(s/60,60), mod(s,60))
elseif s < DAY then
return format("%dh %dm", s/(60*60), mod(s/60,60))
else
return format("%dd %dh", s/DAY, (s / HOUR) - (floor(s/DAY) * 24))
end
end
local function UpdateTooltip(self)
GameTooltip:SetUnitAura(self.__unit, self:GetParent().aura.name, self:GetParent().aura.rank, self:GetParent().aura.filter)
end
local function OnEnter(self)
if(not self:IsVisible()) then return end
GameTooltip:SetOwner(self, "ANCHOR_BOTTOMRIGHT")
self:UpdateTooltip()
end
local function OnLeave(self)
GameTooltip:Hide()
end
local function SetAnchors(self)
local bars = self.bars
for index = 1, getn(bars) do
local frame = bars[index]
local anchor = frame.anchor
frame:SetHeight(self.auraBarHeight or 20)
frame.statusBar.iconHolder:SetWidth(frame:GetHeight())
frame.statusBar.iconHolder:SetHeight(frame:GetHeight())
frame:SetWidth((self.auraBarWidth or self:GetWidth()) - (frame:GetHeight() + (self.gap or 0)))
frame:ClearAllPoints()
if self.down == true then
if self == anchor then -- Root frame so indent for icon
frame:SetPoint("TOPLEFT", anchor, "TOPLEFT", (frame:GetHeight() + (self.gap or 0) ), -1)
else
frame:SetPoint("TOPLEFT", anchor, "BOTTOMLEFT", 0, (-self.spacing or 0))
end
else
if self == anchor then -- Root frame so indent for icon
frame:SetPoint("BOTTOMLEFT", anchor, "BOTTOMLEFT", (frame:GetHeight() + (self.gap or 0)), 1)
else
frame:SetPoint("BOTTOMLEFT", anchor, "TOPLEFT", 0, (self.spacing or 0))
end
end
end
end
local function CreateAuraBar(oUF, anchor)
local auraBarParent = oUF.AuraBars
local frame = CreateFrame("Frame", nil, auraBarParent)
frame:SetHeight(auraBarParent.auraBarHeight or 20)
frame:SetWidth((auraBarParent.auraBarWidth or auraBarParent:GetWidth()) - (frame:GetHeight() + (auraBarParent.gap or 0)))
frame.anchor = anchor
-- the main bar
local statusBar = CreateFrame("StatusBar", nil, frame)
statusBar:SetStatusBarTexture(auraBarParent.auraBarTexture or [[Interface\TargetingFrame\UI-StatusBar]])
statusBar:SetAlpha(auraBarParent.fgalpha or 1)
statusBar:SetAllPoints(frame)
frame.statusBar = statusBar
if auraBarParent.down == true then
if auraBarParent == anchor then -- Root frame so indent for icon
frame:SetPoint("TOPLEFT", anchor, "TOPLEFT", (frame:GetHeight() + (auraBarParent.gap or 0) ), -1)
else
frame:SetPoint("TOPLEFT", anchor, "BOTTOMLEFT", 0, (-auraBarParent.spacing or 0))
end
else
if auraBarParent == anchor then -- Root frame so indent for icon
frame:SetPoint("BOTTOMLEFT", anchor, "BOTTOMLEFT", (frame:GetHeight() + (auraBarParent.gap or 0)), 1)
else
frame:SetPoint("BOTTOMLEFT", anchor, "TOPLEFT", 0, (auraBarParent.spacing or 0))
end
end
local spark = statusBar:CreateTexture(nil, "OVERLAY", nil)
spark:SetTexture([[Interface\CastingBar\UI-CastingBar-Spark]])
spark:SetWidth(12)
spark:SetBlendMode("ADD")
spark:SetPoint("CENTER", statusBar:GetStatusBarTexture(), "RIGHT")
statusBar.spark = spark
statusBar.iconHolder = CreateFrame("Button", nil, statusBar)
statusBar.iconHolder:SetHeight(frame:GetHeight())
statusBar.iconHolder:SetWidth(frame:GetHeight())
statusBar.iconHolder:SetPoint("BOTTOMRIGHT", frame, "BOTTOMLEFT", -auraBarParent.gap, 0)
statusBar.iconHolder.__unit = oUF.unit
statusBar.iconHolder:SetScript("OnEnter", OnEnter)
statusBar.iconHolder:SetScript("OnLeave", OnLeave)
statusBar.iconHolder.UpdateTooltip = UpdateTooltip
statusBar.icon = statusBar.iconHolder:CreateTexture(nil, "BACKGROUND")
statusBar.icon:SetTexCoord(.07, .93, .07, .93)
statusBar.icon:SetAllPoints()
statusBar.spelltime = statusBar:CreateFontString(nil, "ARTWORK")
if auraBarParent.spellTimeObject then
statusBar.spelltime:SetFontObject(auraBarParent.spellTimeObject)
else
statusBar.spelltime:SetFont(auraBarParent.spellTimeFont or [[Fonts\FRIZQT__.TTF]], auraBarParent.spellTimeSize or 10)
end
statusBar.spelltime:SetTextColor(1, 1, 1)
statusBar.spelltime:SetJustifyH("RIGHT")
statusBar.spelltime:SetJustifyV("CENTER")
statusBar.spelltime:SetPoint("RIGHT", 0, 0)
statusBar.spellname = statusBar:CreateFontString(nil, "ARTWORK")
if auraBarParent.spellNameObject then
statusBar.spellname:SetFontObject(auraBarParent.spellNameObject)
else
statusBar.spellname:SetFont(auraBarParent.spellNameFont or [[Fonts\FRIZQT__.TTF]], auraBarParent.spellNameSize or 10)
end
statusBar.spellname:SetTextColor(1, 1, 1)
statusBar.spellname:SetJustifyH("LEFT")
statusBar.spellname:SetJustifyV("CENTER")
statusBar.spellname:SetPoint("LEFT", 0, 0)
statusBar.spellname:SetPoint("RIGHT", statusBar.spelltime, "LEFT")
if auraBarParent.PostCreateBar then
auraBarParent.PostCreateBar(frame)
end
return frame
end
local function UpdateBars(auraBars)
local bars = auraBars.bars
local timenow = GetTime()
for index = 1, getn(bars) do
local frame = bars[index]
local bar = frame.statusBar
if not frame:IsVisible() then
break
end
if bar.aura.noTime then
bar.spelltime:SetText()
bar.spark:Hide()
else
local timeleft = bar.aura.expirationTime - timenow
bar:SetValue(timeleft)
bar.spelltime:SetText(FormatTime(timeleft))
if auraBars.spark == true then
if (auraBars.scaleTime and ((auraBars.scaleTime <= 0) or (auraBars.scaleTime > 0 and timeleft < auraBars.scaleTime))) then
bar.spark:Show()
else
bar.spark:Hide()
end
end
end
end
end
local function DefaultFilter(self, unit, name, rank, icon, count, debuffType, duration, expirationTime, unitCaster, isStealable, shouldConsolidate)
if unitCaster == "player" and not shouldConsolidate then
return true
end
end
local sort = function(a, b)
local compa, compb = a.noTime and huge or a.expirationTime, b.noTime and huge or b.expirationTime
return compa > compb
end
local function Update(self, event, unit)
if self.unit ~= unit then return end
local auraBars = self.AuraBars
local helpOrHarm
local isFriend = UnitIsFriend("player", unit) == 1 and true or false
local both = false
if auraBars.friendlyAuraType and auraBars.enemyAuraType then
if isFriend then
helpOrHarm = auraBars.friendlyAuraType
else
helpOrHarm = auraBars.enemyAuraType
end
else
helpOrHarm = isFriend and "HELPFUL" or "HARMFUL"
end
if helpOrHarm == "BOTH" then
both = true
helpOrHarm = "HELPFUL"
end
-- Create a table of auras to display
local auras = {}
local lastAuraIndex = 0
local counter = 0
if auraBars.forceShow then
for index = 1, auraBars.maxBars do
local spellID = 47540
local name, rank, icon = GetSpellInfo(spellID)
local count, debuffType, duration, expirationTime, unitCaster, isStealable, shouldConsolidate = 5, "Magic", 0, 0, "player", nil, nil
lastAuraIndex = lastAuraIndex + 1
auras[lastAuraIndex] = {}
auras[lastAuraIndex].spellID = spellID
auras[lastAuraIndex].name = name
auras[lastAuraIndex].rank = rank
auras[lastAuraIndex].icon = icon
auras[lastAuraIndex].count = count
auras[lastAuraIndex].debuffType = debuffType
auras[lastAuraIndex].duration = duration
auras[lastAuraIndex].expirationTime = expirationTime
auras[lastAuraIndex].unitCaster = unitCaster
auras[lastAuraIndex].isStealable = isStealable
auras[lastAuraIndex].noTime = (duration == 0 and expirationTime == 0)
auras[lastAuraIndex].filter = helpOrHarm
auras[lastAuraIndex].shouldConsolidate = shouldConsolidate
end
else
for index = 1, 40 do
local name, rank, icon, count, debuffType, duration, expirationTime, unitCaster, isStealable, shouldConsolidate, spellID
if not both then
name, rank, icon, count, debuffType, duration, expirationTime, unitCaster, isStealable, shouldConsolidate, spellID = UnitAura(unit, index, helpOrHarm)
if not name then break end
else
name, rank, icon, count, debuffType, duration, expirationTime, unitCaster, isStealable, shouldConsolidate, spellID = UnitAura(unit, index, "HELPFUL")
if not name then
name, rank, icon, count, debuffType, duration, expirationTime, unitCaster, isStealable, shouldConsolidate, spellID = UnitAura(unit, index, "HARMFUL")
if not name then break end
end
end
if (auraBars.filter or DefaultFilter)(self, unit, name, rank, icon, count, debuffType, duration, expirationTime, unitCaster, isStealable, shouldConsolidate, spellID) then
lastAuraIndex = lastAuraIndex + 1
auras[lastAuraIndex] = {}
auras[lastAuraIndex].spellID = spellID
auras[lastAuraIndex].name = name
auras[lastAuraIndex].rank = rank
auras[lastAuraIndex].icon = icon
auras[lastAuraIndex].count = count
auras[lastAuraIndex].debuffType = debuffType
auras[lastAuraIndex].duration = duration
auras[lastAuraIndex].expirationTime = expirationTime
auras[lastAuraIndex].unitCaster = unitCaster
auras[lastAuraIndex].isStealable = isStealable
auras[lastAuraIndex].noTime = (duration == 0 and expirationTime == 0)
auras[lastAuraIndex].filter = helpOrHarm
auras[lastAuraIndex].shouldConsolidate = shouldConsolidate
end
end
end
if auraBars.sort and not auraBars.forceShow then
tsort(auras, type(auraBars.sort) == "function" and auraBars.sort or sort)
end
for i=1, getn(auras) do
if i > auraBars.maxBars then
tremove(auras, i)
else
lastAuraIndex = i
end
end
-- Show and configure bars for buffs/debuffs.
local bars = auraBars.bars
if lastAuraIndex == 0 then
self.AuraBars:SetHeight(1)
end
for index = 1 , lastAuraIndex do
-- if auraBars:GetWidth() == 0 then break end
local aura = auras[index]
local frame = bars[index]
if not frame then
frame = CreateAuraBar(self, index == 1 and auraBars or bars[index - 1])
bars[index] = frame
end
if index == lastAuraIndex then
if self.AuraBars.down then
self.AuraBars:SetHeight(self.AuraBars:GetTop() - frame:GetBottom())
elseif frame:GetTop() and self.AuraBars:GetBottom() then
self.AuraBars:SetHeight(frame:GetTop() - self.AuraBars:GetBottom())
else
self.AuraBars:SetHeight(20)
end
end
local bar = frame.statusBar
frame.index = index
-- Backup the details of the aura onto the bar, so the OnUpdate function can use it
bar.aura = aura
-- Configure
if bar.aura.noTime then
bar:SetMinMaxValues(0, 1)
bar:SetValue(1)
else
if auraBars.scaleTime and auraBars.scaleTime > 0 then
local maxvalue = min(auraBars.scaleTime, bar.aura.duration)
bar:SetMinMaxValues(0, auraBars.scaleTime)
bar:SetWidth(
( maxvalue / auraBars.scaleTime ) *
( ( auraBars.auraBarWidth or auraBars:GetWidth() ) -
( bar:GetHeight() + (auraBars.gap or 0) ) ) ) -- icon size + gap
else
bar:SetMinMaxValues(0, bar.aura.duration)
end
bar:SetValue(bar.aura.expirationTime - GetTime())
end
bar.icon:SetTexture(bar.aura.icon)
-- bar.spellname:SetText(bar.aura.count > 1 and format("%s [%d]", bar.aura.name, bar.aura.count) or bar.aura.name)
bar.spelltime:SetText(not bar.noTime and FormatTime(bar.aura.expirationTime-GetTime()))
-- Colour bars
local r, g, b = .2, .6, 1 -- Colour for buffs
if auraBars.buffColor then
r, g, b = unpack(auraBars.buffColor)
end
if helpOrHarm == "HARMFUL" then
local debuffType = bar.aura.debuffType and bar.aura.debuffType or "none"
r, g, b = DebuffTypeColor[debuffType].r, DebuffTypeColor[debuffType].g, DebuffTypeColor[debuffType].b
if auraBars.debuffColor then
r, g, b = unpack(auraBars.debuffColor)
else
if debuffType == "none" and auraBars.defaultDebuffColor then
r, g, b = unpack(auraBars.defaultDebuffColor)
end
end
end
bar:SetStatusBarColor(r, g, b)
frame:Show()
end
-- Hide unused bars.
for index = lastAuraIndex + 1, getn(bars) do
bars[index]:Hide()
end
if auraBars.PostUpdate then
auraBars:PostUpdate(event, unit)
end
end
local function Enable(self)
if self.AuraBars then
self:RegisterEvent("PLAYER_AURAS_CHANGED", Update)
self.AuraBars:SetHeight(1)
self.AuraBars.bars = self.AuraBars.bars or {}
self.AuraBars.SetAnchors = SetAnchors
self.AuraBars:SetScript("OnUpdate", function() UpdateBars(self.AuraBars) end)
self.AuraBars.maxBars = self.AuraBars.maxBars or 40
return true
end
end
local function Disable(self)
local auraFrame = self.AuraBars
if auraFrame then
self:UnregisterEvent("PLAYER_AURAS_CHANGED", Update)
auraFrame:SetScript("OnUpdate", nil)
end
end
oUF:AddElement("AuraBars", Update, Enable, Disable)
@@ -1,3 +0,0 @@
<Ui xmlns="http://www.blizzard.com/wow/ui/">
<Script file="oUF_AuraBars.lua"/>
</Ui>
@@ -1,5 +1,4 @@
<Ui xmlns="http://www.blizzard.com/wow/ui/">
<Include file="oUF_AuraBars\oUF_AuraBars.xml"/>
<Include file="oUF_Smooth\oUF_Smooth.xml"/>
<Include file="oUF_GPS\oUF_GPS.xml"/>
</Ui>
+1 -1
View File
@@ -143,7 +143,7 @@ L["Healer"] = "治疗"
L["High Resolution"] = "高分辨率"
L["high"] = ""
L["Icons Only"] = "图标"
L["If you have an icon or aurabar that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "如果你有不想显示的图标或光环条, 你可以简单的通过按住Shift右键点击使它隐藏."
L["If you have an icon that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "如果你有不想显示的图标或光环条, 你可以简单的通过按住Shift右键点击使它隐藏."
L["Importance: |cff07D400High|r"] = "重要度: |cff07D400高|r"
L["Importance: |cffD3CF00Medium|r"] = "重要性: |cffD3CF00中|r"
L["Importance: |cffFF0000Low|r"] = "重要性:|cffFF0000低|r"
+1 -1
View File
@@ -143,7 +143,7 @@ L["Healer"] = true;
L["High Resolution"] = true;
L["high"] = true;
L["Icons Only"] = true; --Also used in Bags
L["If you have an icon or aurabar that you don't want to display simply hold down shift and right click the icon for it to disapear."] = true;
L["If you have an icon that you don't want to display simply hold down shift and right click the icon for it to disapear."] = true;
L["Importance: |cff07D400High|r"] = true;
L["Importance: |cffD3CF00Medium|r"] = true;
L["Importance: |cffFF0000Low|r"] = true;
+1 -1
View File
@@ -143,7 +143,7 @@ L["Healer"] = "Soigneur"
L["High Resolution"] = "Haute Résolution"
L["high"] = "Haute"
L["Icons Only"] = "Icônes seulement" --Also used in Bags
L["If you have an icon or aurabar that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "Si vous avez une icône ou une barre d'aura que vous ne souhaitez pas afficher il suffit de maintenir la touche MAJ enfoncée et d'effectuer un clic droit sur l'icône correspondante pour la faire disparaitre."
L["If you have an icon that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "Si vous avez une icône ou une barre d'aura que vous ne souhaitez pas afficher il suffit de maintenir la touche MAJ enfoncée et d'effectuer un clic droit sur l'icône correspondante pour la faire disparaitre."
L["Importance: |cff07D400High|r"] = "Importance: |cff07D400Haute|r"
L["Importance: |cffD3CF00Medium|r"] = "Importance: |cffD3CF00Moyenne|r"
L["Importance: |cffFF0000Low|r"] = "Importance: |cffFF0000Faible|r"
+1 -1
View File
@@ -143,7 +143,7 @@ L["Healer"] = "Heiler"
L["High Resolution"] = "Hohe Auflösung"
L["high"] = "hoch"
L["Icons Only"] = "Nur Symbole" --Also used in Bags
L["If you have an icon or aurabar that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "Wenn du ein Symbol oder eine Aurenleiste nicht angezeigt haben möchtest, dann halte Shift gedrückt und klicke mit Rechtsklick auf das Symbol um es auszublenden."
L["If you have an icon that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "Wenn du ein Symbol oder eine Aurenleiste nicht angezeigt haben möchtest, dann halte Shift gedrückt und klicke mit Rechtsklick auf das Symbol um es auszublenden."
L["Importance: |cff07D400High|r"] = "Bedeutung: |cff07D400Hoch|r"
L["Importance: |cffD3CF00Medium|r"] = "Bedeutung: |cffD3CF00Mittel|r"
L["Importance: |cffFF0000Low|r"] = "Bedeutung: |cffD3CF00Niedrig|r"
+1 -1
View File
@@ -143,7 +143,7 @@ L["Healer"] = "힐러"
L["High Resolution"] = "고해상도 세팅"
L["high"] = ""
L["Icons Only"] = "아이콘만 표시"
L["If you have an icon or aurabar that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "표시하고 싶지 않은 버프/디버프가 보이면 아이콘을 Shift 우클릭하세요. 차단 목록에 등록되어 보이지 않게 됩니다."
L["If you have an icon that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "표시하고 싶지 않은 버프/디버프가 보이면 아이콘을 Shift 우클릭하세요. 차단 목록에 등록되어 보이지 않게 됩니다."
L["Importance: |cff07D400High|r"] = "중요도: |cff07D400높음|r"
L["Importance: |cffD3CF00Medium|r"] = "중요도: |cffD3CF00보통|r"
L["Importance: |cffFF0000Low|r"] = "중요도 : |cffFF0000낮음|r"
+1 -1
View File
@@ -143,7 +143,7 @@ L["Healer"] = "Curandeiro"
L["High Resolution"] = "Alta Resolução"
L["high"] = "alto"
L["Icons Only"] = "Apenas Ícones"
L["If you have an icon or aurabar that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "Se existir um ícone ou uma barra de aura que você não queira ver exibida simplesmente mantenha pressionada a tecla Shift e clique no ícone com o botão direito para que o ícone/barra de aura desapareça."
L["If you have an icon that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "Se existir um ícone ou uma barra de aura que você não queira ver exibida simplesmente mantenha pressionada a tecla Shift e clique no ícone com o botão direito para que o ícone/barra de aura desapareça."
L["Importance: |cff07D400High|r"] = "Importância: |cff07D400Alta|r"
L["Importance: |cffD3CF00Medium|r"] = "Importância: |cffD3CF00Média|r"
L["Importance: |cffFF0000Low|r"] = "Importância: |cffFF0000Baixa|r"
+1 -1
View File
@@ -143,7 +143,7 @@ L["Healer"] = "Лекарь"
L["High Resolution"] = "Высокое разрешение"
L["high"] = "высоким"
L["Icons Only"] = "Только иконки" --Also used in Bags
L["If you have an icon or aurabar that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "Если Вы видите иконку или полосу аур, которую Вы не хотите отображать, просто зажмите shift и кликните на иконке правой кнопкой, чтобы она исчезла."
L["If you have an icon that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "Если Вы видите иконку или полосу аур, которую Вы не хотите отображать, просто зажмите shift и кликните на иконке правой кнопкой, чтобы она исчезла."
L["Importance: |cff07D400High|r"] = "Важность: |cff07D400Высокая|r"
L["Importance: |cffD3CF00Medium|r"] = "Важность: |cffD3CF00Средняя|r"
L["Importance: |cffFF0000Low|r"] = "Важность: |cffFF0000Низкая|r"
+1 -1
View File
@@ -143,7 +143,7 @@ L["Healer"] = "Sanador"
L["High Resolution"] = "Alta Resolución"
L["high"] = "alta"
L["Icons Only"] = "Sólo Iconos"
L["If you have an icon or aurabar that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "Si tienes un icono o una barra de aura que no quieres ver simplemente mantén pulsado la tecla Shift y haz clic con el botón izquierdo del ratón en el icono para que desaparezca."
L["If you have an icon that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "Si tienes un icono o una barra de aura que no quieres ver simplemente mantén pulsado la tecla Shift y haz clic con el botón izquierdo del ratón en el icono para que desaparezca."
L["Importance: |cff07D400High|r"] = "Importancia: |cff07D400Alta|r"
L["Importance: |cffD3CF00Medium|r"] = "Importancia: |cffD3CF00Media|r"
L["Importance: |cffFF0000Low|r"] = "Importancia: |cffFF0000Baja|r"
+1 -1
View File
@@ -143,7 +143,7 @@ L["Healer"] = "補師"
L["High Resolution"] = "高解析度"
L["high"] = ""
L["Icons Only"] = "圖示" --Also used in Bags
L["If you have an icon or aurabar that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "如果你有不想顯示的圖示或光環條, 你可以簡單的通過按住Shift + 右鍵點擊使它隱藏."
L["If you have an icon that you don't want to display simply hold down shift and right click the icon for it to disapear."] = "如果你有不想顯示的圖示或光環條, 你可以簡單的通過按住Shift + 右鍵點擊使它隱藏."
L["Importance: |cff07D400High|r"] = "重要性: |cff07D400高|r"
L["Importance: |cffD3CF00Medium|r"] = "重要性: |cffD3CF00中|r"
L["Importance: |cffFF0000Low|r"] = "重要性: |cffFF0000低|r"
@@ -1,287 +0,0 @@
local E, L, V, P, G = unpack(ElvUI) --Import: Engine, Locales, PrivateDB, ProfileDB, GlobalDB
local UF = E:GetModule("UnitFrames")
--Cache global variables
--Lua functions
local match = string.match
local strsplit = strsplit
local tostring = tostring
local format = format
local getn = table.getn
--WoW API / Variables
local CreateFrame = CreateFrame
local IsShiftKeyDown = IsShiftKeyDown
local IsAltKeyDown = IsAltKeyDown
local IsControlKeyDown = IsControlKeyDown
local UnitIsFriend = UnitIsFriend
local UnitIsUnit = UnitIsUnit
local UnitCanAttack = UnitCanAttack
local RAID_CLASS_COLORS = RAID_CLASS_COLORS
function UF:Construct_AuraBars()
local bar = self.statusBar
E:SetTemplate(self, "Default", nil, nil, UF.thinBorders, true)
local inset = UF.thinBorders and E.mult or nil
E:SetInside(bar, self, inset, inset)
UF.statusbars[bar] = true
UF:Update_StatusBar(bar)
UF:Configure_FontString(bar.spelltime)
UF:Configure_FontString(bar.spellname)
UF:Update_FontString(bar.spelltime)
UF:Update_FontString(bar.spellname)
bar.spellname:ClearAllPoints()
E:Point(bar.spellname, "LEFT", bar, "LEFT", 2, 0)
E:Point(bar.spellname, "RIGHT", bar.spelltime, "LEFT", -4, 0)
-- bar.spellname:SetWordWrap(false)
E:SetTemplate(bar.iconHolder, "Default", nil, nil, UF.thinBorders, true)
E:SetInside(bar.icon, bar.iconHolder, inset, inset)
bar.icon:SetDrawLayer("OVERLAY")
bar.bg = bar:CreateTexture(nil, "BORDER")
bar.bg:Hide()
bar.iconHolder:RegisterForClicks("RightButtonUp")
bar.iconHolder:SetScript("OnClick", function(self)
if E.db.unitframe.auraBlacklistModifier == "NONE" or not ((E.db.unitframe.auraBlacklistModifier == "SHIFT" and IsShiftKeyDown()) or (E.db.unitframe.auraBlacklistModifier == "ALT" and IsAltKeyDown()) or (E.db.unitframe.auraBlacklistModifier == "CTRL" and IsControlKeyDown())) then return; end
local auraName = self:GetParent().aura.name
if auraName then
E:Print(format(L["The spell '%s' has been added to the Blacklist unitframe aura filter."], auraName))
E.global["unitframe"]["aurafilters"]["Blacklist"]["spells"][auraName] = {
["enable"] = true,
["priority"] = 0,
}
UF:Update_AllFrames()
end
end)
end
function UF:Construct_AuraBarHeader(frame)
local auraBar = CreateFrame("Frame", nil, frame)
auraBar:SetFrameLevel(frame.RaisedElementParent:GetFrameLevel() + 10) --Make them appear above any text element
auraBar.PostCreateBar = UF.Construct_AuraBars
auraBar.gap = (-frame.BORDER + frame.SPACING*3)
auraBar.spacing = (-frame.BORDER + frame.SPACING*3)
auraBar.spark = true
auraBar.filter = UF.AuraBarFilter
auraBar.PostUpdate = UF.ColorizeAuraBars
return auraBar
end
function UF:Configure_AuraBars(frame)
if not frame.VARIABLES_SET then return end
local auraBars = frame.AuraBars
local db = frame.db
if db.aurabar.enable then
if not frame:IsElementEnabled("AuraBars") then
frame:EnableElement("AuraBars")
end
auraBars:Show()
auraBars.friendlyAuraType = db.aurabar.friendlyAuraType
auraBars.enemyAuraType = db.aurabar.enemyAuraType
auraBars.scaleTime = db.aurabar.uniformThreshold
local buffColor = self.db.colors.auraBarBuff
local debuffColor = self.db.colors.auraBarDebuff
local attachTo = frame
if E:CheckClassColor(buffColor.r, buffColor.g, buffColor.b) then
buffColor = E.myclass == "PRIEST" and E.PriestColors or (CUSTOM_CLASS_COLORS and CUSTOM_CLASS_COLORS[E.myclass] or RAID_CLASS_COLORS[E.myclass])
end
if E:CheckClassColor(debuffColor.r, debuffColor.g, debuffColor.b) then
debuffColor = E.myclass == "PRIEST" and E.PriestColors or (CUSTOM_CLASS_COLORS and CUSTOM_CLASS_COLORS[E.myclass] or RAID_CLASS_COLORS[E.myclass])
end
if db.aurabar.attachTo == "BUFFS" then
attachTo = frame.Buffs
elseif db.aurabar.attachTo == "DEBUFFS" then
attachTo = frame.Debuffs
elseif db.aurabar.attachTo == "PLAYER_AURABARS" and ElvUF_Player then
attachTo = ElvUF_Player.AuraBars
end
local anchorPoint, anchorTo = "BOTTOM", "TOP"
if db.aurabar.anchorPoint == "BELOW" then
anchorPoint, anchorTo = "TOP", "BOTTOM"
end
local yOffset
local spacing = (((db.aurabar.attachTo == "FRAME" and 3) or (db.aurabar.attachTo == "PLAYER_AURABARS" and 4) or 2) * frame.SPACING)
local border = (((db.aurabar.attachTo == "FRAME" or db.aurabar.attachTo == "PLAYER_AURABARS") and 2 or 1) * frame.BORDER)
if db.aurabar.anchorPoint == "BELOW" then
yOffset = -spacing + border - (not db.aurabar.yOffset and 0 or db.aurabar.yOffset)
else
yOffset = spacing - border + (not db.aurabar.yOffset and 0 or db.aurabar.yOffset)
end
local xOffset = (db.aurabar.attachTo == "FRAME" and frame.SPACING or 0)
local offsetLeft = xOffset + ((db.aurabar.attachTo == "FRAME" and ((anchorTo == "TOP" and frame.ORIENTATION ~= "LEFT") or (anchorTo == "BOTTOM" and frame.ORIENTATION == "LEFT"))) and frame.POWERBAR_OFFSET or 0)
local offsetRight = -xOffset - ((db.aurabar.attachTo == "FRAME" and ((anchorTo == "TOP" and frame.ORIENTATION ~= "RIGHT") or (anchorTo == "BOTTOM" and frame.ORIENTATION == "RIGHT"))) and frame.POWERBAR_OFFSET or 0)
auraBars.auraBarHeight = db.aurabar.height
auraBars:ClearAllPoints()
E:Point(auraBars, anchorPoint.."LEFT", attachTo, anchorTo.."LEFT", offsetLeft, yOffset)
E:Point(auraBars, anchorPoint.."RIGHT", attachTo, anchorTo.."RIGHT", offsetRight, yOffset)
auraBars.buffColor = {buffColor.r, buffColor.g, buffColor.b}
if UF.db.colors.auraBarByType then
auraBars.debuffColor = nil;
auraBars.defaultDebuffColor = {debuffColor.r, debuffColor.g, debuffColor.b}
else
auraBars.debuffColor = {debuffColor.r, debuffColor.g, debuffColor.b}
auraBars.defaultDebuffColor = nil;
end
auraBars.down = db.aurabar.anchorPoint == "BELOW"
if db.aurabar.sort == "TIME_REMAINING" then
auraBars.sort = true --default function
elseif db.aurabar.sort == "TIME_REMAINING_REVERSE" then
auraBars.sort = self.SortAuraBarReverse
elseif db.aurabar.sort == "TIME_DURATION" then
auraBars.sort = self.SortAuraBarDuration
elseif db.aurabar.sort == "TIME_DURATION_REVERSE" then
auraBars.sort = self.SortAuraBarDurationReverse
elseif db.aurabar.sort == "NAME" then
auraBars.sort = self.SortAuraBarName
else
auraBars.sort = nil
end
auraBars.maxBars = db.aurabar.maxBars
auraBars.forceShow = frame.forceShowAuras
-- auraBars:SetAnchors()
else
if frame:IsElementEnabled("AuraBars") then
frame:DisableElement("AuraBars")
auraBars:Hide()
end
end
end
local huge = math.huge
function UF.SortAuraBarReverse(a, b)
local compa, compb = a.noTime and huge or a.expirationTime, b.noTime and huge or b.expirationTime
return compa < compb
end
function UF.SortAuraBarDuration(a, b)
local compa, compb = a.noTime and huge or a.duration, b.noTime and huge or b.duration
return compa > compb
end
function UF.SortAuraBarDurationReverse(a, b)
local compa, compb = a.noTime and huge or a.duration, b.noTime and huge or b.duration
return compa < compb
end
function UF.SortAuraBarName(a, b)
return a.name > b.name
end
function UF:CheckFilter(name, caster, spellID, isFriend, isPlayer, isUnit, allowDuration, noDuration, canDispell, ...)
-- local friendCheck, filterName, filter, filterType, spellList, spell
-- for i=1, select("#", ...) do
-- filterName = select(i, ...)
-- friendCheck = (isFriend and match(filterName, "^Friendly:([^,]*)")) or (not isFriend and match(filterName, "^Enemy:([^,]*)")) or nil
-- if friendCheck ~= false then
-- if friendCheck ~= nil and (G.unitframe.specialFilters[friendCheck] or E.global.unitframe.aurafilters[friendCheck]) then
-- filterName = friendCheck -- this is for our filters to handle Friendly and Enemy
-- end
-- filter = E.global.unitframe.aurafilters[filterName]
-- if filter then
-- filterType = filter.type
-- spellList = filter.spells
-- spell = spellList and (spellList[spellID] or spellList[name])
-- if filterType and (filterType == "Whitelist") and (spell and spell.enable) and allowDuration then
-- return true, spell.priority -- this is the only difference from auarbars code
-- elseif filterType and (filterType == "Blacklist") and (spell and spell.enable) then
-- return false
-- end
-- elseif filterName == "Personal" and isPlayer and allowDuration then
-- return true
-- elseif filterName == "nonPersonal" and (not isPlayer) and allowDuration then
-- return true
-- elseif filterName == "CastByUnit" and (caster and isUnit) and allowDuration then
-- return true
-- elseif filterName == "notCastByUnit" and (caster and not isUnit) and allowDuration then
-- return true
-- elseif filterName == "Dispellable" and canDispell and allowDuration then
-- return true
-- elseif filterName == "blockNoDuration" and noDuration then
-- return false
-- elseif filterName == "blockNonPersonal" and (not isPlayer) then
-- return false
-- end
-- end
-- end
return true
end
function UF:AuraBarFilter(unit, name, _, _, _, debuffType, duration, _, unitCaster, isStealable, _, spellID)
if not self.db then return end
local db = self.db.aurabar
if not name then return nil end
local filterCheck, isUnit, isFriend, isPlayer, canDispell, allowDuration, noDuration
if db.priority ~= "" then
noDuration = (not duration or duration == 0)
isFriend = unit and UnitIsFriend("player", unit) and not UnitCanAttack("player", unit)
isPlayer = (unitCaster == "player")
isUnit = unit and unitCaster and UnitIsUnit(unit, unitCaster)
canDispell = (self.type == "Buffs" and isStealable) or (self.type == "Debuffs" and debuffType and E:IsDispellableByMe(debuffType))
allowDuration = noDuration or (duration and (duration > 0) and (db.maxDuration == 0 or duration <= db.maxDuration) and (db.minDuration == 0 or duration >= db.minDuration))
filterCheck = UF:CheckFilter(name, unitCaster, spellID, isFriend, isPlayer, isUnit, allowDuration, noDuration, canDispell, strsplit(",", db.priority))
else
filterCheck = true -- Allow all auras to be shown when the filter list is empty
end
return filterCheck
end
function UF:ColorizeAuraBars()
local bars = self.bars
for index = 1, getn(bars) do
local frame = bars[index]
if not frame:IsVisible() then break end
local spellName = frame.statusBar.aura.name
local spellID = frame.statusBar.aura.spellID
-- local colors = E.global.unitframe.AuraBarColors[spellID] or E.global.unitframe.AuraBarColors[tostring(spellID)] or E.global.unitframe.AuraBarColors[spellName]
-- if E.db.unitframe.colors.auraBarTurtle and (E.global.unitframe.aurafilters.TurtleBuffs.spells[spellID] or E.global.unitframe.aurafilters.TurtleBuffs.spells[spellName]) and not colors then
-- colors = E.db.unitframe.colors.auraBarTurtleColor
-- end
if colors then
frame.statusBar:SetStatusBarColor(colors.r, colors.g, colors.b)
frame.statusBar.bg:SetTexture(colors.r * 0.25, colors.g * 0.25, colors.b * 0.25)
else
local r, g, b = frame.statusBar:GetStatusBarColor()
frame.statusBar.bg:SetTexture(r * 0.25, g * 0.25, b * 0.25)
end
if UF.db.colors.transparentAurabars and not frame.statusBar.isTransparent then
UF:ToggleTransparentStatusBar(true, frame.statusBar, frame.statusBar.bg, nil, true)
elseif(frame.statusBar.isTransparent and not UF.db.colors.transparentAurabars) then
UF:ToggleTransparentStatusBar(false, frame.statusBar, frame.statusBar.bg, nil, true)
end
if UF.db.colors.transparentAurabars then
local _, _, _, alpha = frame:GetBackdropColor()
if colors then
frame:SetBackdropColor(colors.r * 0.58, colors.g * 0.58, colors.b * 0.58, alpha)
else
local r, g, b = frame.statusBar:GetStatusBarColor()
frame:SetBackdropColor(r * 0.58, g * 0.58, b * 0.58, alpha)
end
end
end
end
@@ -1,5 +1,4 @@
<Ui xmlns="http://www.blizzard.com/wow/ui/">
<Script file="AuraBars.lua"/>
<Script file="Auras.lua"/>
<Script file="Castbar.lua"/>
<Script file="Classbars.lua"/>
@@ -35,7 +35,6 @@ function UF:Construct_TargetFrame(frame)
frame.InfoPanel = self:Construct_InfoPanel(frame)
frame.MouseGlow = self:Construct_MouseGlow(frame)
frame.TargetGlow = self:Construct_TargetGlow(frame)
frame.AuraBars = self:Construct_AuraBarHeader(frame)
frame.Range = self:Construct_Range(frame)
frame.PvPIndicator = self:Construct_PvPIcon(frame)
frame.customTexts = {}
@@ -116,8 +115,6 @@ function UF:Update_TargetFrame(frame, db)
UF:Configure_RaidIcon(frame)
UF:Configure_AuraBars(frame)
UF:Configure_Range(frame)
UF:Configure_PVPIcon(frame)
-82
View File
@@ -694,13 +694,9 @@ P["unitframe"] = {
["classbackdrop"] = false,
["healthmultiplier"] = 0.6,
["bgUseBarTexture"] = false,
["auraBarByType"] = true,
["auraBarTurtle"] = true,
["auraBarTurtleColor"] = {r = 143/255, g = 101/255, b = 158/255},
["transparentHealth"] = false,
["transparentPower"] = false,
["transparentCastbar"] = false,
["transparentAurabars"] = false,
["castColor"] = {r = .31, g = .31, b = .31},
["castClassColor"] = false,
["castReactionColor"] = false,
@@ -710,8 +706,6 @@ P["unitframe"] = {
["health_backdrop_dead"] = {r = .8, g = .01, b = .01},
["tapped"] = {r = 0.55, g = 0.57, b = 0.61},
["disconnected"] = {r = 0.84, g = 0.75, b = 0.65},
["auraBarBuff"] = {r = .31, g = .31, b = .31},
["auraBarDebuff"] = {r = 0.8, g = 0.1, b = 0.1},
["power"] = {
["MANA"] = {r = 0.31, g = 0.45, b = 0.63},
["RAGE"] = {r = 0.78, g = 0.25, b = 0.25},
@@ -944,25 +938,6 @@ P["unitframe"] = {
["frameLevel"] = 1
},
},
["aurabar"] = {
["enable"] = true,
["anchorPoint"] = "ABOVE",
["attachTo"] = "DEBUFFS",
["maxBars"] = 6,
["useBlacklist"] = true,
["useWhitelist"] = true,
["noDuration"] = true,
["minDuration"] = 0,
["maxDuration"] = 120,
["useFilter"] = "",
["friendlyAuraType"] = "HELPFUL",
["enemyAuraType"] = "HARMFUL",
["height"] = 20,
["sort"] = "TIME_REMAINING",
["uniformThreshold"] = 0,
["yOffset"] = 0,
["spacing"] = 0,
},
["raidicon"] = {
["enable"] = true,
["size"] = 18,
@@ -1114,25 +1089,6 @@ P["unitframe"] = {
["frameLevel"] = 1
}
},
["aurabar"] = {
["enable"] = true,
["anchorPoint"] = "ABOVE",
["attachTo"] = "DEBUFFS",
["maxBars"] = 6,
["useBlacklist"] = {friendly = true, enemy = true},
["useWhitelist"] = {friendly = false, enemy = false},
["noDuration"] = {friendly = true, enemy = true},
["minDuration"] = 0,
["maxDuration"] = 300,
["useFilter"] = "",
["friendlyAuraType"] = "HELPFUL",
["enemyAuraType"] = "HARMFUL",
["height"] = 20,
["sort"] = "TIME_REMAINING",
["uniformThreshold"] = 0,
["yOffset"] = 0,
["spacing"] = 0,
},
["raidicon"] = {
["enable"] = true,
["size"] = 18,
@@ -1443,25 +1399,6 @@ P["unitframe"] = {
["frameLevel"] = 1
}
},
["aurabar"] = {
["enable"] = false,
["anchorPoint"] = "ABOVE",
["attachTo"] = "DEBUFFS",
["maxBars"] = 3,
["useBlacklist"] = {friendly = true, enemy = true},
["useWhitelist"] = {friendly = false, enemy = false},
["noDuration"] = {friendly = false, enemy = false},
["minDuration"] = 0,
["maxDuration"] = 120,
["useFilter"] = "",
["friendlyAuraType"] = "HELPFUL",
["enemyAuraType"] = "HARMFUL",
["height"] = 20,
["sort"] = "TIME_REMAINING",
["uniformThreshold"] = 0,
["yOffset"] = 0,
["spacing"] = 0,
},
["raidicon"] = {
["enable"] = true,
["size"] = 18,
@@ -1660,25 +1597,6 @@ P["unitframe"] = {
["xOffset"] = 0,
["yOffset"] = 0
},
["aurabar"] = {
["enable"] = false,
["anchorPoint"] = "ABOVE",
["attachTo"] = "FRAME",
["maxBars"] = 6,
["useBlacklist"] = {friendly = true, enemy = true},
["useWhitelist"] = {friendly = false, enemy = false},
["noDuration"] = {friendly = true, enemy = true},
["minDuration"] = 0,
["maxDuration"] = 120,
["useFilter"] = "",
["friendlyAuraType"] = "HELPFUL",
["enemyAuraType"] = "HARMFUL",
["height"] = 20,
["sort"] = "TIME_REMAINING",
["uniformThreshold"] = 0,
["yOffset"] = 2,
["spacing"] = 2
},
["buffIndicator"] = {
["enable"] = true,
["size"] = 8,
-1
View File
@@ -804,7 +804,6 @@ L["Class Power"] = "能量条职业色"
L["Class Resources"] = "职业能量"
L["Click Through"] = "点击穿透"
L["Color all buffs that reduce the unit's incoming damage."] = "减少目标受到伤害的所有 Buff 的颜色"
L["Color aurabar debuffs by type."] = "按类型显示光环条颜色"
L["Color castbars by the class of player units."] = "按职业显示施法条颜色"
L["Color castbars by the reaction type of non-player units."] = "按非玩家单位的声望显示施法条颜色"
L["Color health by amount remaining."] = "按数值变化血量颜色"
-1
View File
@@ -793,7 +793,6 @@ L["Class Power"] = true;
L["Class Resources"] = true;
L["Click Through"] = true;
L["Color all buffs that reduce the unit's incoming damage."] = true;
L["Color aurabar debuffs by type."] = true;
L["Color castbars by the class of player units."] = true;
L["Color castbars by the reaction type of non-player units."] = true;
L["Color health by amount remaining."] = true;
-1
View File
@@ -804,7 +804,6 @@ L["Class Power"] = "Énergie selon la Classe"
L["Class Resources"] = "Ressources des Classes"
L["Click Through"] = "Clic à travers"
L["Color all buffs that reduce the unit's incoming damage."] = "Colorer toutes les améliorations réduisant les dégâts entrants de l'unité."
L["Color aurabar debuffs by type."] = "Colore les affaiblissement de la barre d'auras par catégorie."
L["Color castbars by the class of player units."] = true;
L["Color castbars by the reaction type of non-player units."] = true;
L["Color health by amount remaining."] = "Colore le cadre selon la vie restante."
-1
View File
@@ -805,7 +805,6 @@ L["Class Power"] = "Klassen Kraft"
L["Class Resources"] = "Klassenressourcen"
L["Click Through"] = "Klicke hindurch"
L["Color all buffs that reduce the unit's incoming damage."] = "Färbe alle Stärkungszauber die den einkommenden Schaden der Einheit verringern."
L["Color aurabar debuffs by type."] = "Färbe Schwächungszauber nach Typ."
L["Color castbars by the class of player units."] = "Fäbre die Zauberleiste entsprechend ihrer Klasse."
L["Color castbars by the reaction type of non-player units."] = "Färbe die Zauberleiste entsprechend der Reaktion der Einheit."
L["Color health by amount remaining."] = "Färbe die Gesundheitsleiste entsprechend der aktuell verbleibenden Lebenspunkte"
-1
View File
@@ -852,7 +852,6 @@ L["Class Power"] = "직업색상 사용"
L["Class Resources"] = "직업별 특수 자원바"
L["Click Through"] = "마우스 무시"
L["Color all buffs that reduce the unit's incoming damage."] = "유닛이 입는 데미지를 줄이는 모든 생존류 기술에 이 색상을 적용합니다."
L["Color aurabar debuffs by type."] = "디버프 종류에 따라서 클래스타이머의 색상을 따로 입힙니다.|n|n예로 독계열 디버프는 초록색 바로 표시되게 됩니다."
L["Color castbars by the class of player units."] = true;
L["Color castbars by the reaction type of non-player units."] = true;
L["Color health by amount remaining."] = "기존에 설정된 색상에서 생명력이 줄어들 때 마다 점차 빨간색으로 변화합니다."
@@ -804,7 +804,6 @@ L["Class Power"] = "Poder por classe"
L["Class Resources"] = "Recursos de Classe"
L["Click Through"] = "Clicar através"
L["Color all buffs that reduce the unit's incoming damage."] = "Colorir todos os bônus que reduzem o dano recebido pela unidade."
L["Color aurabar debuffs by type."] = "Colorir penalidades da barra de auras por tipo."
L["Color castbars by the class of player units."] = true;
L["Color castbars by the reaction type of non-player units."] = true;
L["Color health by amount remaining."] = "Colorir a vida pela quantidade restante."
-1
View File
@@ -804,7 +804,6 @@ L["Class Power"] = "Ресурс по классу"
L["Class Resources"] = "Ресурсы класса"
L["Click Through"] = "Клик насквозь"
L["Color all buffs that reduce the unit's incoming damage."] = "Окрашивать все баффы, уменьшающие входящий урон по цели."
L["Color aurabar debuffs by type."] = "Окрашивать полосы аур-дебаффов по типу"
L["Color castbars by the class of player units."] = "Окрашивать полосу заклинаний по цвету класса игроков."
L["Color castbars by the reaction type of non-player units."] = "Окрашивать полосу заклинаний по цвету реакции НИП."
L["Color health by amount remaining."] = "Окрашивает полосу здоровья в зависимости от оставшегося его количества."
-1
View File
@@ -804,7 +804,6 @@ L["Class Power"] = "Poder de Clase"
L["Class Resources"] = "Recursos de Clase"
L["Click Through"] = "Clic A través"
L["Color all buffs that reduce the unit's incoming damage."] = "Colorea todos los beneficios que reduzcan el daño recibido por la unidad."
L["Color aurabar debuffs by type."] = "Color de los perjuicios de la barra de aura por tipo"
L["Color castbars by the class of player units."] = true;
L["Color castbars by the reaction type of non-player units."] = true;
L["Color health by amount remaining."] = "Color de salud por la cantidad restante."
@@ -803,7 +803,6 @@ L["Class Power"] = "能量條職業色"
L["Class Resources"] = "職業能量"
L["Click Through"] = "點擊穿透"
L["Color all buffs that reduce the unit's incoming damage."] = "減少目標受到的傷害的所有 Buff 的顏色."
L["Color aurabar debuffs by type."] = "按類型顯示光環條顔色."
L["Color castbars by the class of player units."] = "按職業顯示施法條顏色"
L["Color castbars by the reaction type of non-player units."] = "按非玩家單位的聲望顯示施法條顏色"
L["Color health by amount remaining."] = "按數值變化血量顏色."
+2 -362
View File
@@ -101,277 +101,6 @@ local CUSTOMTEXT_CONFIGS = {}
-----------------------------------------------------------------------
-- OPTIONS TABLES
-----------------------------------------------------------------------
local function GetOptionsTable_AuraBars(friendlyOnly, updateFunc, groupName)
local config = {
order = 800,
type = "group",
name = L["Aura Bars"],
get = function(info) return E.db.unitframe.units[groupName].aurabar[ info[getn(info)] ] end,
set = function(info, value) E.db.unitframe.units[groupName].aurabar[ info[getn(info)] ] = value updateFunc(UF, groupName) end,
args = {
header = {
order = 1,
type = "header",
name = L["Aura Bars"]
},
enable = {
order = 2,
type = "toggle",
name = L["Enable"]
},
configureButton1 = {
order = 3,
type = "execute",
name = L["Coloring"],
desc = L["This opens the UnitFrames Color settings. These settings affect all unitframes."],
func = function() ACD:SelectGroup("ElvUI", "unitframe", "generalOptionsGroup", "allColorsGroup", "auraBars") end,
},
configureButton2 = {
order = 4,
type = "execute",
name = L["Coloring (Specific)"],
func = function() E:SetToFilterConfig("AuraBar Colors") end
},
anchorPoint = {
order = 5,
type = "select",
name = L["Anchor Point"],
desc = L["What point to anchor to the frame you set to attach to."],
values = {
["ABOVE"] = L["Above"],
["BELOW"] = L["Below"]
}
},
attachTo = {
order = 6,
type = "select",
name = L["Attach To"],
desc = L["The object you want to attach to."],
values = {
["FRAME"] = L["Frame"],
["DEBUFFS"] = L["Debuffs"],
["BUFFS"] = L["Buffs"]
}
},
height = {
order = 7,
type = "range",
name = L["Height"],
min = 6, max = 40, step = 1
},
maxBars = {
order = 8,
type = "range",
name = L["Max Bars"],
min = 1, max = 40, step = 1
},
sort = {
order = 9,
type = "select",
name = L["Sort Method"],
values = {
["TIME_REMAINING"] = L["Time Remaining"],
["TIME_REMAINING_REVERSE"] = L["Time Remaining Reverse"],
["TIME_DURATION"] = L["Duration"],
["TIME_DURATION_REVERSE"] = L["Duration Reverse"],
["NAME"] = NAME,
["NONE"] = NONE
}
},
friendlyAuraType = {
order = 16,
type = "select",
name = L["Friendly Aura Type"],
desc = L["Set the type of auras to show when a unit is friendly."],
values = {
["HARMFUL"] = L["Debuffs"],
["HELPFUL"] = L["Buffs"]
}
},
enemyAuraType = {
order = 17,
type = "select",
name = L["Enemy Aura Type"],
desc = L["Set the type of auras to show when a unit is a foe."],
values = {
["HARMFUL"] = L["Debuffs"],
["HELPFUL"] = L["Buffs"]
}
},
uniformThreshold = {
order = 18,
type = "range",
name = L["Uniform Threshold"],
desc = L["Seconds remaining on the aura duration before the bar starts moving. Set to 0 to disable."],
min = 0, max = 3600, step = 1
},
yOffset = {
order = 19,
type = "range",
name = L["yOffset"],
min = -1000, max = 1000, step = 1,
},
spacing = {
order = 20,
type = "range",
name = L["Spacing"],
min = 0, softMax = 20, step = 1,
},
filters = {
order = 500,
type = "group",
name = FILTERS,
guiInline = true,
args = {}
}
}
}
if groupName == "target" then
config.args.attachTo.values["PLAYER_AURABARS"] = L["Player Frame Aura Bars"]
end
if friendlyOnly then
config.args.filters.args.useBlacklist = {
order = 10,
type = "toggle",
name = L["Block Blacklisted Auras"],
desc = L["Don't display any auras found on the 'Blacklist' filter."],
}
config.args.filters.args.useWhitelist = {
order = 11,
type = "toggle",
name = L["Allow Whitelisted Auras"],
desc = L["If no other filter options are being used then it will block anything not on the 'Whitelist' filter, otherwise it will simply add auras on the whitelist in addition to any other filter settings."]
}
config.args.filters.args.noDuration = {
order = 12,
type = "toggle",
name = L["Block Auras Without Duration"],
desc = L["Don't display auras that have no duration."]
}
config.args.filters.args.useFilter = {
order = 14,
type = "select",
name = L["Additional Filter"],
desc = L["Select an additional filter to use. If the selected filter is a whitelist and no other filters are being used (with the exception of Block Non-Personal Auras) then it will block anything not on the whitelist, otherwise it will simply add auras on the whitelist in addition to any other filter settings."],
values = function()
filters = {}
filters[""] = NONE
for filter in pairs(E.global.unitframe.aurafilters) do
filters[filter] = filter
end
return filters
end
}
else
config.args.filters.args.useBlacklist = {
order = 10,
type = "group",
guiInline = true,
name = L["Block Blacklisted Auras"],
args = {
friendly = {
order = 1,
type = "toggle",
name = L["Friendly"],
desc = L["If the unit is friendly to you."].." "..L["Don't display any auras found on the 'Blacklist' filter."],
get = function(info) return E.db.unitframe.units[groupName].aurabar.useBlacklist.friendly end,
set = function(info, value) E.db.unitframe.units[groupName].aurabar.useBlacklist.friendly = value updateFunc(UF, groupName) end
},
enemy = {
order = 2,
type = "toggle",
name = L["Enemy"],
desc = L["If the unit is an enemy to you."].." "..L["Don't display any auras found on the 'Blacklist' filter."],
get = function(info) return E.db.unitframe.units[groupName].aurabar.useBlacklist.enemy end,
set = function(info, value) E.db.unitframe.units[groupName].aurabar.useBlacklist.enemy = value updateFunc(UF, groupName) end
}
}
}
config.args.filters.args.useWhitelist = {
order = 11,
type = "group",
guiInline = true,
name = L["Allow Whitelisted Auras"],
args = {
friendly = {
order = 1,
type = "toggle",
name = L["Friendly"],
desc = L["If the unit is friendly to you."].." "..L["If no other filter options are being used then it will block anything not on the 'Whitelist' filter, otherwise it will simply add auras on the whitelist in addition to any other filter settings."],
get = function(info) return E.db.unitframe.units[groupName].aurabar.useWhitelist.friendly end,
set = function(info, value) E.db.unitframe.units[groupName].aurabar.useWhitelist.friendly = value updateFunc(UF, groupName) end,
},
enemy = {
order = 2,
type = "toggle",
name = L["Enemy"],
desc = L["If the unit is an enemy to you."].." "..L["If no other filter options are being used then it will block anything not on the 'Whitelist' filter, otherwise it will simply add auras on the whitelist in addition to any other filter settings."],
get = function(info) return E.db.unitframe.units[groupName].aurabar.useWhitelist.enemy end,
set = function(info, value) E.db.unitframe.units[groupName].aurabar.useWhitelist.enemy = value updateFunc(UF, groupName) end
}
}
}
config.args.filters.args.noDuration = {
order = 12,
type = "group",
guiInline = true,
name = L["Block Auras Without Duration"],
args = {
friendly = {
order = 1,
type = "toggle",
name = L["Friendly"],
desc = L["If the unit is friendly to you."].." "..L["Don't display auras that have no duration."],
get = function(info) return E.db.unitframe.units[groupName].aurabar.noDuration.friendly end,
set = function(info, value) E.db.unitframe.units[groupName].aurabar.noDuration.friendly = value updateFunc(UF, groupName) end
},
enemy = {
order = 2,
type = "toggle",
name = L["Enemy"],
desc = L["If the unit is an enemy to you."].." "..L["Don't display auras that have no duration."],
get = function(info) return E.db.unitframe.units[groupName].aurabar.noDuration.enemy end,
set = function(info, value) E.db.unitframe.units[groupName].aurabar.noDuration.enemy = value updateFunc(UF, groupName) end
}
}
}
config.args.filters.args.useFilter = {
order = 14,
type = "select",
name = L["Additional Filter"],
desc = L["Select an additional filter to use. If the selected filter is a whitelist and no other filters are being used (with the exception of Block Non-Personal Auras) then it will block anything not on the whitelist, otherwise it will simply add auras on the whitelist in addition to any other filter settings."],
values = function()
filters = {}
filters[""] = NONE
for filter in pairs(E.global.unitframe.aurafilters) do
filters[filter] = filter
end
return filters
end
}
end
config.args.filters.args.minDuration = {
order = 17,
type = "range",
name = L["Minimum Duration"],
desc = L["Don't display auras that are shorter than this duration (in seconds). Set to zero to disable."],
min = 0, max = 10800, step = 1,
}
config.args.filters.args.maxDuration = {
order = 18,
type = "range",
name = L["Maximum Duration"],
desc = L["Don't display auras that are longer than this duration (in seconds). Set to zero to disable."],
min = 0, max = 10800, step = 1
}
return config
end
local function GetOptionsTable_Auras(friendlyUnitOnly, auraType, isGroupFrame, updateFunc, groupName, numUnits)
local config = {
order = auraType == "buffs" and 500 or 600,
@@ -2791,93 +2520,8 @@ E.Options.args.unitframe = {
}
}
},
auraBars = {
order = 6,
type = "group",
name = L["Aura Bars"],
args = {
header = {
order = 1,
type = "header",
name = L["Aura Bars"]
},
transparentAurabars = {
order = 2,
type = "toggle",
name = L["Transparent"],
desc = L["Make textures transparent."],
get = function(info) return E.db.unitframe.colors[ info[getn(info)] ] end,
set = function(info, value) E.db.unitframe.colors[ info[getn(info)] ] = value UF:Update_AllFrames() end,
},
auraBarByType = {
order = 3,
type = "toggle",
name = L["By Type"],
desc = L["Color aurabar debuffs by type."]
},
auraBarTurtle = {
order = 4,
type = "toggle",
name = L["Color Turtle Buffs"],
desc = L["Color all buffs that reduce the unit's incoming damage."]
},
BUFFS = {
order = 5,
type = "color",
name = L["Buffs"],
get = function(info)
local t = E.db.unitframe.colors.auraBarBuff
local d = P.unitframe.colors.auraBarBuff
return t.r, t.g, t.b, t.a, d.r, d.g, d.b
end,
set = function(info, r, g, b)
if E:CheckClassColor(r, g, b) then
local classColor = E.myclass == "PRIEST" and E.PriestColors or (CUSTOM_CLASS_COLORS and CUSTOM_CLASS_COLORS[E.myclass] or RAID_CLASS_COLORS[E.myclass])
r = classColor.r
g = classColor.g
b = classColor.b
end
local t = E.db.unitframe.colors.auraBarBuff
t.r, t.g, t.b = r, g, b
UF:Update_AllFrames()
end
},
DEBUFFS = {
order = 6,
type = "color",
name = L["Debuffs"],
get = function(info)
local t = E.db.unitframe.colors.auraBarDebuff
local d = P.unitframe.colors.auraBarDebuff
return t.r, t.g, t.b, t.a, d.r, d.g, d.b
end,
set = function(info, r, g, b)
local t = E.db.unitframe.colors.auraBarDebuff
t.r, t.g, t.b = r, g, b
UF:Update_AllFrames()
end
},
auraBarTurtleColor = {
order = 7,
type = "color",
name = L["Turtle Color"],
get = function(info)
local t = E.db.unitframe.colors.auraBarTurtleColor
local d = P.unitframe.colors.auraBarTurtleColor
return t.r, t.g, t.b, t.a, d.r, d.g, d.b
end,
set = function(info, r, g, b)
local t = E.db.unitframe.colors.auraBarTurtleColor
t.r, t.g, t.b = r, g, b
UF:Update_AllFrames()
end
}
}
},
healPrediction = {
order = 7,
order = 6,
name = L["Heal Prediction"],
type = "group",
get = function(info)
@@ -2921,7 +2565,7 @@ E.Options.args.unitframe = {
}
},
debuffHighlight = {
order = 8,
order = 7,
type = "group",
name = L["Debuff Highlighting"],
get = function(info)
@@ -3223,7 +2867,6 @@ E.Options.args.unitframe.args.player = {
buffs = GetOptionsTable_Auras(true, "buffs", false, UF.CreateAndUpdateUF, "player"),
debuffs = GetOptionsTable_Auras(true, "debuffs", false, UF.CreateAndUpdateUF, "player"),
castbar = GetOptionsTable_Castbar(true, UF.CreateAndUpdateUF, "player"),
aurabar = GetOptionsTable_AuraBars(true, UF.CreateAndUpdateUF, "player"),
raidicon = GetOptionsTable_RaidIcon(UF.CreateAndUpdateUF, "player"),
classbar = {
order = 750,
@@ -3853,7 +3496,6 @@ E.Options.args.unitframe.args.target = {
buffs = GetOptionsTable_Auras(false, "buffs", false, UF.CreateAndUpdateUF, "target"),
debuffs = GetOptionsTable_Auras(false, "debuffs", false, UF.CreateAndUpdateUF, "target"),
castbar = GetOptionsTable_Castbar(false, UF.CreateAndUpdateUF, "target"),
aurabar = GetOptionsTable_AuraBars(false, UF.CreateAndUpdateUF, "target"),
raidicon = GetOptionsTable_RaidIcon(UF.CreateAndUpdateUF, "target"),
GPSArrow = GetOptionsTableForNonGroup_GPS("target"),
combobar = {
@@ -4489,7 +4131,6 @@ E.Options.args.unitframe.args.targettargettarget = {
buffs = GetOptionsTable_Auras(false, "buffs", false, UF.CreateAndUpdateUF, "focus"),
debuffs = GetOptionsTable_Auras(false, "debuffs", false, UF.CreateAndUpdateUF, "focus"),
castbar = GetOptionsTable_Castbar(false, UF.CreateAndUpdateUF, "focus"),
aurabar = GetOptionsTable_AuraBars(false, UF.CreateAndUpdateUF, "focus"),
raidicon = GetOptionsTable_RaidIcon(UF.CreateAndUpdateUF, "focus"),
GPSArrow = GetOptionsTableForNonGroup_GPS("focus"),
}
@@ -4799,7 +4440,6 @@ E.Options.args.unitframe.args.pet = {
buffs = GetOptionsTable_Auras(true, "buffs", false, UF.CreateAndUpdateUF, "pet"),
debuffs = GetOptionsTable_Auras(true, "debuffs", false, UF.CreateAndUpdateUF, "pet"),
castbar = GetOptionsTable_Castbar(false, UF.CreateAndUpdateUF, "pet"),
aurabar = GetOptionsTable_AuraBars(true, UF.CreateAndUpdateUF, "pet"),
happiness = {
order = 700,
type = "group",