Add Fade/MI Color to the options. This color is used on players under the effects of MI/Fade.

This commit is contained in:
Xinhuan
2009-01-02 10:45:34 +08:00
parent 4c06c56dea
commit f88be07553
9 changed files with 44 additions and 7 deletions
+2
View File
@@ -174,6 +174,8 @@ L["Use Class Colors"] = "Klassenfarben benutzen"
L["Use standard class colors for the background color of threat bars"] = "Benutze die Standard Klassenfarben für den Hintergrund der Bedrohungsbalken"
L["Pet Bar Color"] = "Begleiterleistenfarbe"
L["The background color for pets"] = "Die Hintergrundfarbe für Begleiter"
L["Fade/MI Bar Color"] = true
L["The background color for players under the effects of Fade and Mirror Image (they will be at negative 4 million threat)"] = true
L["Bar BG Color"] = "Balkenhintergrundfarbe"
L["The background color for all threat bars"] = "Die Hintergrundfarbe für alle Bedrohungsbalken"
L["Always Show Self"] = "Selbst immer anzeigen"
+2
View File
@@ -174,6 +174,8 @@ L["Use Class Colors"] = true
L["Use standard class colors for the background color of threat bars"] = true
L["Pet Bar Color"] = true
L["The background color for pets"] = true
L["Fade/MI Bar Color"] = true
L["The background color for players under the effects of Fade and Mirror Image (they will be at negative 4 million threat)"] = true
L["Bar BG Color"] = true
L["The background color for all threat bars"] = true
L["Always Show Self"] = true
+2
View File
@@ -174,6 +174,8 @@ L["Use Class Colors"] = true
L["Use standard class colors for the background color of threat bars"] = true
L["Pet Bar Color"] = true
L["The background color for pets"] = true
L["Fade/MI Bar Color"] = true
L["The background color for players under the effects of Fade and Mirror Image (they will be at negative 4 million threat)"] = true
L["Bar BG Color"] = true
L["The background color for all threat bars"] = true
L["Always Show Self"] = true
+2
View File
@@ -174,6 +174,8 @@ L["Use Class Colors"] = "Couleurs de classe"
L["Use standard class colors for the background color of threat bars"] = "Utilise les couleurs de classes standards comme couleur d'arrière-plan des barres de menace."
L["Pet Bar Color"] = true
L["The background color for pets"] = true
L["Fade/MI Bar Color"] = true
L["The background color for players under the effects of Fade and Mirror Image (they will be at negative 4 million threat)"] = true
L["Bar BG Color"] = "Couleur A-P des barres"
L["The background color for all threat bars"] = "La couleur de l'arrière-plan de toutes les barres de menace."
L["Always Show Self"] = "Tj afficher soi-même"
+2
View File
@@ -174,6 +174,8 @@ L["Use Class Colors"] = "직업 색상 사용"
L["Use standard class colors for the background color of threat bars"] = "위협 바의 배경 색상을 기본 직업 색상으로 사용합니다."
L["Pet Bar Color"] = "소환수 바 색상"
L["The background color for pets"] = "소환수에 대한 배경 색상을 지정합니다."
L["Fade/MI Bar Color"] = true
L["The background color for players under the effects of Fade and Mirror Image (they will be at negative 4 million threat)"] = true
L["Bar BG Color"] = "배경 색상 바"
L["The background color for all threat bars"] = "모든 위협 바들에 대한 배경 색상을 지정합니다."
L["Always Show Self"] = "항상 자신 표시"
+2
View File
@@ -174,6 +174,8 @@ L["Use Class Colors"] = "Цвет класса"
L["Use standard class colors for the background color of threat bars"] = "Использовать стандартный цвет уласса в качестве цвета фона полосы угрозы"
L["Pet Bar Color"] = "Цвет полосы питомца"
L["The background color for pets"] = "Цвет фона питомцев"
L["Fade/MI Bar Color"] = true
L["The background color for players under the effects of Fade and Mirror Image (they will be at negative 4 million threat)"] = true
L["Bar BG Color"] = "Цвет фона полос"
L["The background color for all threat bars"] = "Цвет фона для всех полос угрозы"
L["Always Show Self"] = "Всегда показ себя"
+2
View File
@@ -174,6 +174,8 @@ L["Use Class Colors"] = "使用职业颜色"
L["Use standard class colors for the background color of threat bars"] = "使用标准职业颜色威胁计量条背景颜色"
L["Pet Bar Color"] = true
L["The background color for pets"] = true
L["Fade/MI Bar Color"] = true
L["The background color for players under the effects of Fade and Mirror Image (they will be at negative 4 million threat)"] = true
L["Bar BG Color"] = "计量条背景颜色"
L["The background color for all threat bars"] = "所有威胁计量条背景颜色"
L["Always Show Self"] = "总是显示自己"
+2
View File
@@ -174,6 +174,8 @@ L["Use Class Colors"] = "使用職業顏色"
L["Use standard class colors for the background color of threat bars"] = "使用標準職業顏色威脅棒條背景顏色"
L["Pet Bar Color"] = "寵物棒條顏色"
L["The background color for pets"] = "寵物棒條背景顏色"
L["Fade/MI Bar Color"] = true
L["The background color for players under the effects of Fade and Mirror Image (they will be at negative 4 million threat)"] = true
L["Bar BG Color"] = "棒條背景顏色"
L["The background color for all threat bars"] = "所有威脅棒條背景顏色"
L["Always Show Self"] = "總是顯示自己"
+28 -7
View File
@@ -148,6 +148,7 @@ local defaults = {
ShowAggroBar = true,
AggroBarColor = {r = 1, g = 0, b = 0, a = 1,},
PetBarColor = {r = 0.77, g = 0, b = 1, a = 1},
FadeBarColor = {r = 0.5, g = 0.5, b = 0.5, a = 1},
},
ShowWith = {
UseShowWith = true,
@@ -1283,6 +1284,7 @@ local lastWarn = { -- Used to store information for threat warnings
}
local threatStore = {} -- Format: threatStore[i] = threatTable[guid] -- used for storing past threatTables
local threatStoreTime = {} -- Format: threatStoreTime[i] = GetTime()
local negativeTable = {} -- Format: negativeTable[guid] = true -- stores if someone is under the effects of Fade or Mirror Image
local function sortfunction(a, b)
return threatTable[a] > threatTable[b]
@@ -1296,6 +1298,7 @@ local function updatethreat(unitid, mobunitid)
-- Threat can be negative due to temporary threat reduction effects such as Fade and Mirror Image (-410065408).
if threatValue < 0 then
threatValue = threatValue + 410065408
negativeTable[guid] = true
end
if threatValue > topthreat then topthreat = threatValue end
if isTanking then tankGUID = guid end
@@ -1404,6 +1407,7 @@ function Omen:UpdateBarsReal()
threatTable = newTable()
threatTable[mobGUID] = -1
tankGUID = nil
wipe(negativeTable)
-- Get data for threat on mob by scanning the whole raid
if inParty or inRaid then
@@ -1535,7 +1539,8 @@ function Omen:UpdateBarsReal()
end
-- Update the color of the bar
local c = (guid == myGUID and dbBar.UseMyBarColor and dbBar.MyBarColor) or
local c = (negativeTable[guid] and dbBar.FadeBarColor) or
(guid == myGUID and dbBar.UseMyBarColor and dbBar.MyBarColor) or
(guid == tankGUID and dbBar.UseTankBarColor and dbBar.TankBarColor) or
(guid == "AGGRO" and dbBar.AggroBarColor) or
(dbBar.UseClassColors and (RAID_CLASS_COLORS[class] or (class == "PET" and dbBar.PetBarColor))) or
@@ -2584,13 +2589,13 @@ local options = {
},
UseClassColors = {
type = "toggle",
order = 20,
order = 21,
name = L["Use Class Colors"],
desc = L["Use standard class colors for the background color of threat bars"],
},
PetBarColor = {
type = "color",
order = 21,
order = 22,
name = L["Pet Bar Color"],
desc = L["The background color for pets"],
hasAlpha = true,
@@ -2605,11 +2610,21 @@ local options = {
end,
disabled = function() return not db.Bar.UseClassColors end,
},
AlwaysShowSelf = {
type = "toggle",
FadeBarColor = {
type = "color",
order = 26,
name = L["Always Show Self"],
desc = L["Always show your threat bar on Omen (ignores class filter settings), showing your bar on the last row if necessary"],
name = L["Fade/MI Bar Color"],
desc = L["The background color for players under the effects of Fade and Mirror Image (they will be at negative 4 million threat)"],
hasAlpha = true,
get = function(info)
local t = db.Bar.FadeBarColor
return t.r, t.g, t.b, t.a
end,
set = function(info, r, g, b, a)
local t = db.Bar.FadeBarColor
t.r, t.g, t.b, t.a = r, g, b, a
Omen:UpdateBars()
end,
},
BarColor = {
type = "color",
@@ -2628,6 +2643,12 @@ local options = {
end,
disabled = function() return db.Bar.UseClassColors end,
},
AlwaysShowSelf = {
type = "toggle",
order = 28,
name = L["Always Show Self"],
desc = L["Always show your threat bar on Omen (ignores class filter settings), showing your bar on the last row if necessary"],
},
Texture = {
type = "select", dialogControl = 'LSM30_Statusbar',
order = 29,