- Added an option for change the amount of lines on death log.
- Added custom display for CC done.
This commit is contained in:
@@ -16,6 +16,7 @@ locales\Details-deDE.lua
|
||||
locales\Details-frFR.lua
|
||||
locales\Details-koKR.lua
|
||||
locales\Details-ruRU.lua
|
||||
locales\Details-zhCN.lua
|
||||
locales\Details-zhTW.lua
|
||||
|
||||
boot.lua
|
||||
|
||||
@@ -309,8 +309,10 @@
|
||||
--> core
|
||||
|
||||
function combate:CreateLastEventsTable (player_name)
|
||||
--> sixteen indexes, thinking in 32 but it's just too much
|
||||
local t = { {}, {}, {}, {}, {}, {}, {}, {}, {}, {}, {}, {}, {}, {}, {}, {} }
|
||||
local t = {}
|
||||
for i = 1, _detalhes.deadlog_events do
|
||||
t [i] = {}
|
||||
end
|
||||
t.n = 1
|
||||
self.player_last_events [player_name] = t
|
||||
return t
|
||||
|
||||
+125
-4
@@ -227,8 +227,9 @@
|
||||
else
|
||||
actor.report_name = actor.nome
|
||||
end
|
||||
else
|
||||
actor.report_name = actor.nome
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
end
|
||||
@@ -673,7 +674,7 @@
|
||||
if (instancia.row_info.textL_show_number) then
|
||||
bar_number = esta_barra.colocacao .. ". "
|
||||
end
|
||||
|
||||
|
||||
if (self.enemy) then
|
||||
if (self.arena_enemy) then
|
||||
if (UsingCustomLeftText) then
|
||||
@@ -783,22 +784,37 @@
|
||||
return self._ActorTable [index]
|
||||
else
|
||||
--> if is a spell object
|
||||
local class
|
||||
if (actor.id) then
|
||||
local spellname = _GetSpellInfo (actor.id)
|
||||
actor.nome = spellname
|
||||
actor.classe = actor.spellschool
|
||||
class = actor.spellschool
|
||||
else
|
||||
class = actor.classe
|
||||
if (class == "UNKNOW") then
|
||||
--> try once again
|
||||
class = _detalhes:GetClass (actor.nome)
|
||||
if (class and class ~= "UNKNOW") then
|
||||
actor.classe = class
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
local new_actor = _setmetatable ({
|
||||
nome = actor.nome,
|
||||
classe = actor.classe,
|
||||
classe = class,
|
||||
value = _detalhes:GetOrderNumber (actor.nome),
|
||||
}, atributo_custom.mt)
|
||||
|
||||
new_actor.name_complement = name_complement
|
||||
new_actor.displayName = new_actor.nome .. (name_complement or "")
|
||||
new_actor.displayName = _detalhes:GetOnlyName (new_actor.nome) .. (name_complement or "")
|
||||
new_actor.spec = actor.spec
|
||||
|
||||
new_actor.enemy = actor.enemy
|
||||
new_actor.arena_enemy = actor.arena_enemy
|
||||
new_actor.arena_ally = actor.arena_ally
|
||||
|
||||
if (actor.id) then
|
||||
new_actor.id = actor.id
|
||||
new_actor.icon = select (3, _GetSpellInfo (actor.id))
|
||||
@@ -1697,6 +1713,111 @@
|
||||
end
|
||||
end
|
||||
|
||||
----------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
--doas
|
||||
local CC_Done = {
|
||||
name = "Crowd Control",
|
||||
icon = [[Interface\ICONS\Spell_Frost_FreezingBreath]],
|
||||
attribute = false,
|
||||
spellid = false,
|
||||
author = "Details!",
|
||||
desc = "Show the crowd control amount for each player.",
|
||||
source = false,
|
||||
target = false,
|
||||
script_version = 6,
|
||||
script = [[
|
||||
local combat, instance_container, instance = ...
|
||||
local total, top, amount = 0, 0, 0
|
||||
|
||||
local misc_actors = combat:GetActorList (DETAILS_ATTRIBUTE_MISC)
|
||||
|
||||
for index, character in ipairs (misc_actors) do
|
||||
if (character.cc_done) then
|
||||
local cc_done = floor (character.cc_done)
|
||||
instance_container:AddValue (character, cc_done)
|
||||
total = total + cc_done
|
||||
if (cc_done > top) then
|
||||
top = cc_done
|
||||
end
|
||||
amount = amount + 1
|
||||
end
|
||||
end
|
||||
|
||||
return total, top, amount
|
||||
]],
|
||||
tooltip = [[
|
||||
local actor, combat, instance = ...
|
||||
local spells = {}
|
||||
for spellid, spell in pairs (actor.cc_done_spells._ActorTable) do
|
||||
tinsert (spells, {spellid, spell.counter})
|
||||
end
|
||||
|
||||
table.sort (spells, _detalhes.Sort2)
|
||||
|
||||
for index, spell in ipairs (spells) do
|
||||
local name, _, icon = GetSpellInfo (spell [1])
|
||||
GameCooltip:AddLine (name, spell [2])
|
||||
_detalhes:AddTooltipBackgroundStatusbar()
|
||||
GameCooltip:AddIcon (icon, 1, 1, 14, 14)
|
||||
end
|
||||
|
||||
local targets = {}
|
||||
for playername, amount in pairs (actor.cc_done_targets) do
|
||||
tinsert (targets, {playername, amount})
|
||||
end
|
||||
|
||||
table.sort (targets, _detalhes.Sort2)
|
||||
|
||||
_detalhes:AddTooltipSpellHeaderText ("Targets", "yellow", r, g, b, #targets)
|
||||
local class, _, _, _, _, r, g, b = _detalhes:GetClass (actor.nome)
|
||||
GameCooltip:AddStatusBar (100, 1, r, g, b, 1)
|
||||
|
||||
|
||||
for index, target in ipairs (targets) do
|
||||
GameCooltip:AddLine (target[1], target [2])
|
||||
_detalhes:AddTooltipBackgroundStatusbar()
|
||||
|
||||
local class, _, _, _, _, r, g, b = _detalhes:GetClass (target [1])
|
||||
if (class and class ~= "UNKNOW") then
|
||||
local texture, l, r, t, b = _detalhes:GetClassIcon (class)
|
||||
GameCooltip:AddIcon ("Interface\\AddOns\\Details\\images\\classes_small_alpha", 1, 1, 14, 14, l, r, t, b)
|
||||
else
|
||||
GameCooltip:AddIcon ("Interface\\GossipFrame\\IncompleteQuestIcon", 1, 1, 14, 14)
|
||||
end
|
||||
--
|
||||
end
|
||||
]],
|
||||
total_script = [[
|
||||
local value, top, total, combat, instance = ...
|
||||
return floor (value)
|
||||
]],
|
||||
}
|
||||
|
||||
-- /run _detalhes:AddDefaultCustomDisplays()
|
||||
|
||||
local have = false
|
||||
for _, custom in ipairs (self.custom) do
|
||||
if (custom.name == "Crowd Control" and (custom.script_version and custom.script_version >= CC_Done.script_version) ) then
|
||||
have = true
|
||||
break
|
||||
end
|
||||
end
|
||||
if (not have) then
|
||||
setmetatable (CC_Done, _detalhes.atributo_custom)
|
||||
CC_Done.__index = _detalhes.atributo_custom
|
||||
|
||||
for i, custom in ipairs (self.custom) do
|
||||
if (custom.name == "Crowd Control") then
|
||||
table.remove (self.custom, i)
|
||||
tinsert (self.custom, i, CC_Done)
|
||||
have = true
|
||||
end
|
||||
end
|
||||
if (not have) then
|
||||
self.custom [#self.custom+1] = CC_Done
|
||||
end
|
||||
end
|
||||
|
||||
----------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
local MySpells = {
|
||||
|
||||
@@ -1892,6 +1892,33 @@ function _detalhes:AtualizaSegmentos_AfterCombat (instancia, historico)
|
||||
|
||||
end
|
||||
|
||||
local function ValidateAttribute (atributo, sub_atributo)
|
||||
|
||||
if (atributo == 1) then
|
||||
if (sub_atributo < 0 or sub_atributo > _detalhes.atributos[1]) then
|
||||
return false
|
||||
end
|
||||
elseif (atributo == 2) then
|
||||
if (sub_atributo < 0 or sub_atributo > _detalhes.atributos[2]) then
|
||||
return false
|
||||
end
|
||||
elseif (atributo == 3) then
|
||||
if (sub_atributo < 0 or sub_atributo > _detalhes.atributos[3]) then
|
||||
return false
|
||||
end
|
||||
elseif (atributo == 4) then
|
||||
if (sub_atributo < 0 or sub_atributo > _detalhes.atributos[4]) then
|
||||
return false
|
||||
end
|
||||
elseif (atributo == 5) then
|
||||
return true
|
||||
else
|
||||
return false
|
||||
end
|
||||
|
||||
return true
|
||||
end
|
||||
|
||||
function _detalhes:SetDisplay (segmento, atributo, sub_atributo, iniciando_instancia, InstanceMode)
|
||||
if (not self.meu_id) then
|
||||
return
|
||||
@@ -1916,7 +1943,7 @@ function _detalhes:TrocaTabela (instancia, segmento, atributo, sub_atributo, ini
|
||||
segmento = instancia
|
||||
instancia = self
|
||||
end
|
||||
|
||||
|
||||
if (InstanceMode and InstanceMode ~= instancia:GetMode()) then
|
||||
instancia:AlteraModo (instancia, InstanceMode)
|
||||
end
|
||||
@@ -1992,6 +2019,12 @@ function _detalhes:TrocaTabela (instancia, segmento, atributo, sub_atributo, ini
|
||||
return
|
||||
end
|
||||
|
||||
if (not ValidateAttribute (atributo, sub_atributo)) then
|
||||
sub_atributo = 1
|
||||
atributo = 1
|
||||
_detalhes:Msg ("invalid attribute, switching to damage done.")
|
||||
end
|
||||
|
||||
--> Muda o segmento caso necessário
|
||||
if (segmento ~= current_segmento or _detalhes.initializing or iniciando_instancia) then
|
||||
|
||||
@@ -2397,6 +2430,8 @@ function _detalhes:MontaAtributosOption (instancia, func)
|
||||
CoolTip:SetOption ("SelectedTopAnchorMod", -2)
|
||||
CoolTip:SetOption ("SelectedBottomAnchorMod", 2)
|
||||
|
||||
CoolTip:SetOption ("TextFont", _detalhes.font_faces.menus)
|
||||
|
||||
local last_selected = atributo_ativo
|
||||
if (atributo_ativo == 5) then
|
||||
last_selected = 6
|
||||
@@ -2777,6 +2812,7 @@ function _detalhes:monta_relatorio (este_relatorio, custom)
|
||||
total, container, first, container_amount, nm = _detalhes.atributo_custom:RefreshWindow (self, self.showing, true, true)
|
||||
if (nm) then
|
||||
name_member = nm
|
||||
print ("nm:", nm)
|
||||
end
|
||||
keyName = "report_value"
|
||||
else
|
||||
@@ -2788,7 +2824,6 @@ function _detalhes:monta_relatorio (este_relatorio, custom)
|
||||
--print (total, keyName, first, atributo, container_amount)
|
||||
end
|
||||
|
||||
|
||||
amt = math.min (amt, container_amount or 0)
|
||||
--amt é zero
|
||||
for i = 1, amt do
|
||||
@@ -2803,7 +2838,7 @@ function _detalhes:monta_relatorio (este_relatorio, custom)
|
||||
amount = _thisActor [keyName]
|
||||
is_string = true
|
||||
end
|
||||
|
||||
|
||||
local name = _thisActor [name_member] .. " "
|
||||
if (_detalhes.remove_realm_from_name and name:find ("-")) then
|
||||
name = name:gsub (("%-.*"), "")
|
||||
|
||||
+120
-44
@@ -198,53 +198,55 @@ function _detalhes:ToolTipDead (instancia, morte, esta_barra, keydown)
|
||||
local time = event [4]
|
||||
local source = event [6]
|
||||
|
||||
if (type (evtype) == "boolean") then
|
||||
--> is damage or heal
|
||||
if (evtype) then
|
||||
--> damage
|
||||
|
||||
local overkill = event [10] or 0
|
||||
if (overkill > 0) then
|
||||
amount = amount - overkill
|
||||
overkill = " (" .. _detalhes:ToK (overkill) .. " |cFFFF8800overkill|r)"
|
||||
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s |cFFFFFF00" .. spellname .. "|r (|cFFC6B0D9" .. source .. "|r)", "-" .. _detalhes:ToK (amount) .. overkill .. " (" .. hp .. "%)", 1, "white", "white")
|
||||
if (time + 12 > hora_da_morte) then
|
||||
if (type (evtype) == "boolean") then
|
||||
--> is damage or heal
|
||||
if (evtype) then
|
||||
--> damage
|
||||
|
||||
local overkill = event [10] or 0
|
||||
if (overkill > 0) then
|
||||
amount = amount - overkill
|
||||
overkill = " (" .. _detalhes:ToK (overkill) .. " |cFFFF8800overkill|r)"
|
||||
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s |cFFFFFF00" .. spellname .. "|r (|cFFC6B0D9" .. source .. "|r)", "-" .. _detalhes:ToK (amount) .. overkill .. " (" .. hp .. "%)", 1, "white", "white")
|
||||
else
|
||||
overkill = ""
|
||||
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s " .. spellname .. " (|cFFC6B0D9" .. source .. "|r)", "-" .. _detalhes:ToK (amount) .. overkill .. " (" .. hp .. "%)", 1, "white", "white")
|
||||
end
|
||||
|
||||
GameCooltip:AddIcon (spellicon)
|
||||
|
||||
if (event [9]) then
|
||||
--> friendly fire
|
||||
GameCooltip:AddStatusBar (hp, 1, "darkorange", true)
|
||||
else
|
||||
--> from a enemy
|
||||
GameCooltip:AddStatusBar (hp, 1, "red", true)
|
||||
end
|
||||
else
|
||||
overkill = ""
|
||||
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s " .. spellname .. " (|cFFC6B0D9" .. source .. "|r)", "-" .. _detalhes:ToK (amount) .. overkill .. " (" .. hp .. "%)", 1, "white", "white")
|
||||
--> heal
|
||||
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s " .. spellname .. " (|cFFC6B0D9" .. source .. "|r)", "+" .. _detalhes:ToK (amount) .. " (" .. hp .. "%)", 1, "white", "white")
|
||||
GameCooltip:AddIcon (spellicon)
|
||||
GameCooltip:AddStatusBar (hp, 1, "green", true)
|
||||
|
||||
end
|
||||
|
||||
GameCooltip:AddIcon (spellicon)
|
||||
|
||||
if (event [9]) then
|
||||
--> friendly fire
|
||||
GameCooltip:AddStatusBar (hp, 1, "darkorange", true)
|
||||
else
|
||||
--> from a enemy
|
||||
GameCooltip:AddStatusBar (hp, 1, "red", true)
|
||||
elseif (type (evtype) == "number") then
|
||||
if (evtype == 1) then
|
||||
--> cooldown
|
||||
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s " .. spellname .. " (" .. source .. ")", "cooldown (" .. hp .. "%)", 1, "white", "white")
|
||||
GameCooltip:AddIcon (spellicon)
|
||||
GameCooltip:AddStatusBar (100, 1, "yellow", true)
|
||||
|
||||
elseif (evtype == 2 and not battleress) then
|
||||
--> battle ress
|
||||
battleress = event
|
||||
|
||||
elseif (evtype == 3) then
|
||||
--> last cooldown used
|
||||
lastcooldown = event
|
||||
|
||||
end
|
||||
else
|
||||
--> heal
|
||||
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s " .. spellname .. " (|cFFC6B0D9" .. source .. "|r)", "+" .. _detalhes:ToK (amount) .. " (" .. hp .. "%)", 1, "white", "white")
|
||||
GameCooltip:AddIcon (spellicon)
|
||||
GameCooltip:AddStatusBar (hp, 1, "green", true)
|
||||
|
||||
end
|
||||
|
||||
elseif (type (evtype) == "number") then
|
||||
if (evtype == 1) then
|
||||
--> cooldown
|
||||
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s " .. spellname .. " (" .. source .. ")", "cooldown (" .. hp .. "%)", 1, "white", "white")
|
||||
GameCooltip:AddIcon (spellicon)
|
||||
GameCooltip:AddStatusBar (100, 1, "yellow", true)
|
||||
|
||||
elseif (evtype == 2 and not battleress) then
|
||||
--> battle ress
|
||||
battleress = event
|
||||
|
||||
elseif (evtype == 3) then
|
||||
--> last cooldown used
|
||||
lastcooldown = event
|
||||
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -278,6 +280,7 @@ function _detalhes:ToolTipDead (instancia, morte, esta_barra, keydown)
|
||||
GameCooltip:SetOption ("LeftBorderSize", -4)
|
||||
GameCooltip:SetOption ("RightBorderSize", 5)
|
||||
GameCooltip:SetOption ("StatusBarTexture", [[Interface\AddOns\Details\images\bar4_reverse]])
|
||||
GameCooltip:SetOption ("StatusBarTexture", [[Interface\AddOns\Details\images\BantoBar]])
|
||||
GameCooltip:SetWallpaper (1, [[Interface\SPELLBOOK\Spellbook-Page-1]], {.6, 0.1, 0.64453125, 0}, {.8, .8, .8, 0.2}, true)
|
||||
|
||||
local myPoint = _detalhes.tooltip.anchor_point
|
||||
@@ -334,11 +337,15 @@ function atributo_misc:ReportSingleDeadLine (morte, instancia)
|
||||
local elapsed = _cstr ("%.1f", evento [4] - time_of_death) .."s"
|
||||
local spellname, _, spellicon = _GetSpellInfo (evento [2])
|
||||
local spelllink
|
||||
if (evento [2] > 10) then
|
||||
|
||||
if (evento [2] == 1) then
|
||||
spelllink = GetSpellLink (6603)
|
||||
elseif (evento [2] > 10) then
|
||||
spelllink = GetSpellLink (evento [2])
|
||||
else
|
||||
spelllink = spellname
|
||||
end
|
||||
|
||||
local source = _detalhes:GetOnlyName (evento [6])
|
||||
local amount = evento [3]
|
||||
local hp = _math_floor (evento [5] / max_health * 100)
|
||||
@@ -2350,6 +2357,12 @@ function atributo_misc:r_onlyrefresh_shadow (actor)
|
||||
|
||||
_detalhes.refresh:r_atributo_misc (actor, shadow)
|
||||
|
||||
--> cc done
|
||||
if (actor.cc_done) then
|
||||
refresh_alvos (shadow.cc_done_targets, actor.cc_done_targets)
|
||||
refresh_habilidades (shadow.cc_done_spells, actor.cc_done_spells)
|
||||
end
|
||||
|
||||
--> cooldowns
|
||||
if (actor.cooldowns_defensive) then
|
||||
refresh_alvos (shadow.cooldowns_defensive_targets, actor.cooldowns_defensive_targets)
|
||||
@@ -2463,6 +2476,19 @@ function atributo_misc:r_connect_shadow (actor, no_refresh)
|
||||
_detalhes.refresh:r_atributo_misc (actor, shadow)
|
||||
end
|
||||
|
||||
if (actor.cc_done) then
|
||||
if (not shadow.cc_done_targets) then
|
||||
shadow.cc_done = _detalhes:GetOrderNumber()
|
||||
shadow.cc_done_targets = {}
|
||||
shadow.cc_done_spells = container_habilidades:NovoContainer (_detalhes.container_type.CONTAINER_MISC_CLASS)
|
||||
end
|
||||
|
||||
shadow.cc_done = shadow.cc_done + actor.cc_done
|
||||
|
||||
somar_alvos (shadow.cc_done_targets, actor.cc_done_targets)
|
||||
somar_habilidades (shadow.cc_done_spells, actor.cc_done_spells)
|
||||
end
|
||||
|
||||
if (actor.cooldowns_defensive) then
|
||||
if (not shadow.cooldowns_defensive_targets) then
|
||||
shadow.cooldowns_defensive = _detalhes:GetOrderNumber (actor.nome)
|
||||
@@ -2650,6 +2676,16 @@ function _detalhes.refresh:r_atributo_misc (este_jogador, shadow)
|
||||
_setmetatable (este_jogador, _detalhes.atributo_misc)
|
||||
este_jogador.__index = _detalhes.atributo_misc
|
||||
|
||||
--> refresh cc done
|
||||
if (este_jogador.cc_done) then
|
||||
if (shadow and not shadow.cc_done_targets) then
|
||||
shadow.cc_done = 0
|
||||
shadow.cc_done_targets = {}
|
||||
shadow.cc_done_spells = container_habilidades:NovoContainer (_detalhes.container_type.CONTAINER_MISC_CLASS)
|
||||
end
|
||||
_detalhes.refresh:r_container_habilidades (este_jogador.cc_done_spells, shadow and shadow.cc_done_spells)
|
||||
end
|
||||
|
||||
--> refresh interrupts
|
||||
if (este_jogador.interrupt_targets) then
|
||||
if (shadow and not shadow.interrupt_targets) then
|
||||
@@ -2740,6 +2776,10 @@ function _detalhes.clear:c_atributo_misc (este_jogador)
|
||||
este_jogador.links = nil
|
||||
este_jogador.minha_barra = nil
|
||||
|
||||
if (este_jogador.cc_done_targets) then
|
||||
_detalhes.clear:c_container_habilidades (este_jogador.cc_done_spells)
|
||||
end
|
||||
|
||||
if (este_jogador.interrupt_targets) then
|
||||
_detalhes.clear:c_container_habilidades (este_jogador.interrupt_spells)
|
||||
end
|
||||
@@ -2772,6 +2812,24 @@ end
|
||||
|
||||
atributo_misc.__add = function (tabela1, tabela2)
|
||||
|
||||
if (tabela2.cc_done) then
|
||||
tabela1.cc_done = tabela1.cc_done + tabela2.cc_done
|
||||
|
||||
for target_name, amount in _pairs (tabela2.cc_done_targets) do
|
||||
tabela1.cc_done_targets [target_name] = (tabela1.cc_done_targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in _pairs (tabela2.cc_done_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.cc_done_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in _pairs (habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
somar_keys (habilidade, habilidade_tabela1)
|
||||
end
|
||||
end
|
||||
|
||||
if (tabela2.interrupt) then
|
||||
|
||||
if (not tabela1.interrupt) then
|
||||
@@ -3012,6 +3070,24 @@ end
|
||||
|
||||
atributo_misc.__sub = function (tabela1, tabela2)
|
||||
|
||||
if (tabela2.cc_done) then
|
||||
tabela1.cc_done = tabela1.cc_done - tabela2.cc_done
|
||||
|
||||
for target_name, amount in _pairs (tabela2.cc_done_targets) do
|
||||
tabela1.cc_done_targets [target_name] = (tabela1.cc_done_targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in _pairs (tabela2.cc_done_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.cc_done_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in _pairs (habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
subtrair_keys (habilidade, habilidade_tabela1)
|
||||
end
|
||||
end
|
||||
|
||||
if (tabela2.interrupt) then
|
||||
--> total de interrupts
|
||||
tabela1.interrupt = tabela1.interrupt - tabela2.interrupt
|
||||
|
||||
@@ -151,6 +151,11 @@ function historico:adicionar (tabela)
|
||||
--print ("0x10")
|
||||
end
|
||||
|
||||
if (not overall_added and (tabela.is_pvp or tabela.is_arena)) then --> is a PvP combat
|
||||
overall_added = true
|
||||
--print ("0x10")
|
||||
end
|
||||
|
||||
if (overall_added) then
|
||||
if (_detalhes.debug) then
|
||||
_detalhes:Msg ("(debug) overall data flag match with the current combat.")
|
||||
|
||||
@@ -411,6 +411,10 @@
|
||||
|
||||
if (not _detalhes.tabela_vigente.is_boss) then
|
||||
|
||||
if (_detalhes.tabela_vigente.is_pvp) then
|
||||
_detalhes:FlagActorsOnPvPCombat()
|
||||
end
|
||||
|
||||
local in_instance = IsInInstance() --> garrison returns party as instance type.
|
||||
if ((InstanceType == "party" or InstanceType == "raid") and in_instance) then
|
||||
_detalhes.tabela_vigente.is_trash = true
|
||||
@@ -875,6 +879,14 @@
|
||||
|
||||
end
|
||||
|
||||
function _detalhes:FlagActorsOnPvPCombat()
|
||||
for class_type, container in _ipairs (_detalhes.tabela_vigente) do
|
||||
for _, actor in _ipairs (container._ActorTable) do
|
||||
actor.pvp_component = true
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function _detalhes:FlagActorsOnBossFight()
|
||||
for class_type, container in _ipairs (_detalhes.tabela_vigente) do
|
||||
for _, actor in _ipairs (container._ActorTable) do
|
||||
|
||||
@@ -15,6 +15,37 @@ function _detalhes:UpdateGears()
|
||||
|
||||
end
|
||||
|
||||
|
||||
|
||||
------------------------------------------------------------------------------------------------------------
|
||||
|
||||
function _detalhes:SetDeathLogLimit (limit)
|
||||
|
||||
if (limit and type (limit) == "number" and limit >= 8) then
|
||||
_detalhes.deadlog_events = limit
|
||||
|
||||
local combat = _detalhes.tabela_vigente
|
||||
|
||||
local wipe = table.wipe
|
||||
for player_name, event_table in pairs (combat.player_last_events) do
|
||||
if (limit > #event_table) then
|
||||
for i = #event_table + 1, limit do
|
||||
event_table [i] = {}
|
||||
end
|
||||
else
|
||||
event_table.n = 1
|
||||
for _, t in ipairs (event_table) do
|
||||
wipe (t)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
_detalhes:UpdateParserGears()
|
||||
end
|
||||
end
|
||||
|
||||
------------------------------------------------------------------------------------------------------------
|
||||
|
||||
function _detalhes:TrackSpecsNow (track_everything)
|
||||
|
||||
local spelllist = _detalhes.SpecSpellList
|
||||
|
||||
+2
-2
@@ -529,7 +529,7 @@
|
||||
while (_iter.data) do --search key: ~deletar ~apagar
|
||||
local can_erase = true
|
||||
|
||||
if (_iter.data.grupo or _iter.data.boss or _iter.data.boss_fight_component) then
|
||||
if (_iter.data.grupo or _iter.data.boss or _iter.data.boss_fight_component or _iter.data.pvp_component) then
|
||||
can_erase = false
|
||||
else
|
||||
local owner = _iter.data.owner
|
||||
@@ -606,7 +606,7 @@
|
||||
while (_iter.data) do --search key: ~deletar ~apagar
|
||||
local can_erase = true
|
||||
|
||||
if (_iter.data.grupo or _iter.data.boss or _iter.data.boss_fight_component or IsBossEncounter) then
|
||||
if (_iter.data.grupo or _iter.data.boss or _iter.data.boss_fight_component or IsBossEncounter or _iter.data.pvp_component) then
|
||||
can_erase = false
|
||||
else
|
||||
local owner = _iter.data.owner
|
||||
|
||||
+116
-47
@@ -1,4 +1,4 @@
|
||||
|
||||
|
||||
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
local _detalhes = _G._detalhes
|
||||
@@ -110,6 +110,8 @@
|
||||
local _recording_buffs_and_debuffs = false
|
||||
--> in combat flag
|
||||
local _in_combat = false
|
||||
--> deathlog
|
||||
local _death_event_amt = 16
|
||||
--> hooks
|
||||
local _hook_cooldowns = false
|
||||
local _hook_deaths = false
|
||||
@@ -145,6 +147,10 @@
|
||||
------------------------------------------------------------------------------------------------
|
||||
--> early checks and fixes
|
||||
|
||||
--SPELL_DAMAGE,0000000000000000,nil,0x512,0x0,Player-1174-080D253A,"Neltuvak-Undermine",0x512,0x0,157247,"Reverberations",0x1,0000000000000000,0000000000000000,0,0,0,0,0,0,0,0,0.00,0.00,0,47061,-1,1,0,0,0,nil,nil,nil,nil
|
||||
--SPELL_DAMAGE,Creature-0-3020-1205-15169-79806-000003513D,"Stone Wall",0x2248,0x0,Player-3209-085116F5,"Xirodots-Azralon",0x514,0x0,161923,"Rune of Crushing Earth",0x8,0000000000000000,0000000000000000,0,0,0,0,0,0,0,0,0.00,0.00,0,72729,-1,8,0,0,0,nil,nil,nil,nil
|
||||
--SPELL_DAMAGE,0000000000000000,nil,0x514,0x0,Player-3677-070E7EAE,"Alithan-Garrosh",0x514,0x0,157659,"Rippling Smash",0x8,0000000000000000,0000000000000000,0,0,0,0,0,0,0,0,0.00,0.00,0,50610,-1,8,0,0,12765,nil,nil,nil,nil
|
||||
|
||||
if (who_serial == "") then
|
||||
if (who_flags and _bit_band (who_flags, OBJECT_TYPE_PETS) ~= 0) then --> é um pet
|
||||
--> pets must have a serial
|
||||
@@ -362,6 +368,10 @@
|
||||
|
||||
local this_event = t [i]
|
||||
|
||||
if (not this_event) then
|
||||
print ("event error", i, _death_event_amt)
|
||||
end
|
||||
|
||||
this_event [1] = true --> true if this is a damage || false for healing
|
||||
this_event [2] = spellid --> spellid || false if this is a battle ress line
|
||||
this_event [3] = amount --> amount of damage or healing
|
||||
@@ -375,7 +385,7 @@
|
||||
|
||||
i = i + 1
|
||||
|
||||
if (i == 17) then
|
||||
if (i == _death_event_amt+1) then
|
||||
t.n = 1
|
||||
else
|
||||
t.n = i
|
||||
@@ -456,7 +466,7 @@
|
||||
this_event [10] = overkill
|
||||
i = i + 1
|
||||
|
||||
if (i == 17) then
|
||||
if (i == _death_event_amt+1) then
|
||||
t.n = 1
|
||||
else
|
||||
t.n = i
|
||||
@@ -849,7 +859,7 @@
|
||||
|
||||
i = i + 1
|
||||
|
||||
if (i == 17) then
|
||||
if (i == _death_event_amt+1) then
|
||||
t.n = 1
|
||||
else
|
||||
t.n = i
|
||||
@@ -980,7 +990,7 @@
|
||||
-- jade spirit doesn't send who_name, that's a shame.
|
||||
if (who_name == alvo_name and raid_members_cache [who_serial] and _in_combat) then
|
||||
--> call record buffs uptime
|
||||
--[[not tail call, need to fix this]] parser:add_buff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "BUFF_UPTIME_IN")
|
||||
parser:add_buff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "BUFF_UPTIME_IN")
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1029,12 +1039,17 @@
|
||||
------------------------------------------------------------------------------------------------
|
||||
--> buff uptime
|
||||
if (_recording_buffs_and_debuffs) then
|
||||
|
||||
if (cc_spell_list [spellid]) then
|
||||
parser:add_cc_done (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname)
|
||||
end
|
||||
|
||||
if (raid_members_cache [who_serial]) then
|
||||
--> call record debuffs uptime
|
||||
--[[not tail call, need to fix this]] parser:add_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "DEBUFF_UPTIME_IN")
|
||||
parser:add_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "DEBUFF_UPTIME_IN")
|
||||
|
||||
elseif (raid_members_cache [alvo_serial] and not raid_members_cache [who_serial]) then --> alvo é da raide é alguem de fora da raide
|
||||
--[[not tail call, need to fix this]] parser:add_bad_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, spellschool, "DEBUFF_UPTIME_IN")
|
||||
elseif (raid_members_cache [alvo_serial] and not raid_members_cache [who_serial]) then --> alvo é da raide e who é alguem de fora da raide
|
||||
parser:add_bad_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, spellschool, "DEBUFF_UPTIME_IN")
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1104,6 +1119,50 @@
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function parser:add_cc_done (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname)
|
||||
|
||||
------------------------------------------------------------------------------------------------
|
||||
--> early checks and fixes
|
||||
|
||||
_current_misc_container.need_refresh = true
|
||||
|
||||
------------------------------------------------------------------------------------------------
|
||||
--> get actors
|
||||
local este_jogador = misc_cache [who_name]
|
||||
if (not este_jogador) then
|
||||
este_jogador = _current_misc_container:PegarCombatente (who_serial, who_name, who_flags, true)
|
||||
misc_cache [who_name] = este_jogador
|
||||
end
|
||||
|
||||
------------------------------------------------------------------------------------------------
|
||||
--> build containers on the fly
|
||||
|
||||
if (not este_jogador.cc_done) then
|
||||
este_jogador.cc_done = _detalhes:GetOrderNumber()
|
||||
este_jogador.cc_done_spells = container_habilidades:NovoContainer (container_misc)
|
||||
este_jogador.cc_done_targets = {}
|
||||
end
|
||||
|
||||
------------------------------------------------------------------------------------------------
|
||||
--> add amount
|
||||
|
||||
--> update last event
|
||||
este_jogador.last_event = _tempo
|
||||
|
||||
--> add amount
|
||||
este_jogador.cc_done = este_jogador.cc_done + 1
|
||||
este_jogador.cc_done_targets [alvo_name] = (este_jogador.cc_done_targets [alvo_name] or 0) + 1
|
||||
|
||||
--> actor spells table
|
||||
local spell = este_jogador.cc_done_spells._ActorTable [spellid]
|
||||
if (not spell) then
|
||||
spell = este_jogador.cc_done_spells:PegaHabilidade (spellid, true)
|
||||
end
|
||||
|
||||
spell.targets [alvo_name] = (spell.targets [alvo_name] or 0) + 1
|
||||
spell.counter = spell.counter + 1
|
||||
end
|
||||
|
||||
function parser:buff_refresh (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, spellschool, tipo, amount)
|
||||
|
||||
@@ -1117,7 +1176,7 @@
|
||||
if (_recording_buffs_and_debuffs) then
|
||||
if (who_name == alvo_name and raid_members_cache [who_serial] and _in_combat) then
|
||||
--> call record buffs uptime
|
||||
--[[not tail call, need to fix this]] parser:add_buff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "BUFF_UPTIME_REFRESH")
|
||||
parser:add_buff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "BUFF_UPTIME_REFRESH")
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1183,9 +1242,9 @@
|
||||
if (_recording_buffs_and_debuffs) then
|
||||
if (raid_members_cache [who_serial]) then
|
||||
--> call record debuffs uptime
|
||||
--[[not tail call, need to fix this]] parser:add_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "DEBUFF_UPTIME_REFRESH")
|
||||
parser:add_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "DEBUFF_UPTIME_REFRESH")
|
||||
elseif (raid_members_cache [alvo_serial] and not raid_members_cache [who_serial]) then --> alvo é da raide e o caster é inimigo
|
||||
--[[not tail call, need to fix this]] parser:add_bad_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, spellschool, "DEBUFF_UPTIME_REFRESH")
|
||||
parser:add_bad_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, spellschool, "DEBUFF_UPTIME_REFRESH")
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1253,7 +1312,7 @@
|
||||
if (_recording_buffs_and_debuffs) then
|
||||
if (who_name == alvo_name and raid_members_cache [who_serial] and _in_combat) then
|
||||
--> call record buffs uptime
|
||||
--[[not tail call, need to fix this]] parser:add_buff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "BUFF_UPTIME_OUT")
|
||||
parser:add_buff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "BUFF_UPTIME_OUT")
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1311,9 +1370,9 @@
|
||||
if (_recording_buffs_and_debuffs) then
|
||||
if (raid_members_cache [who_serial]) then
|
||||
--> call record debuffs uptime
|
||||
--[[not tail call, need to fix this]] parser:add_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "DEBUFF_UPTIME_OUT")
|
||||
parser:add_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, "DEBUFF_UPTIME_OUT")
|
||||
elseif (raid_members_cache [alvo_serial] and not raid_members_cache [who_serial]) then --> alvo é da raide e o caster é inimigo
|
||||
--[[not tail call, need to fix this]] parser:add_bad_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, spellschool, "DEBUFF_UPTIME_OUT")
|
||||
parser:add_bad_debuff_uptime (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, spellschool, "DEBUFF_UPTIME_OUT")
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1747,7 +1806,7 @@
|
||||
this_event [6] = who_name --> source name
|
||||
|
||||
i = i + 1
|
||||
if (i == 17) then
|
||||
if (i == _death_event_amt+1) then
|
||||
t.n = 1
|
||||
else
|
||||
t.n = i
|
||||
@@ -2257,20 +2316,20 @@
|
||||
--lesses index = older / higher index = newer
|
||||
|
||||
local last_index = t.n --or 'next index'
|
||||
if (last_index < 17 and not t[last_index][4]) then
|
||||
if (last_index < _death_event_amt+1 and not t[last_index][4]) then
|
||||
for i = 1, last_index-1 do
|
||||
if (t[i][4] and t[i][4]+16 > time) then
|
||||
if (t[i][4] and t[i][4]+_death_event_amt > time) then
|
||||
_table_insert (esta_morte, t[i])
|
||||
end
|
||||
end
|
||||
else
|
||||
for i = last_index, 16 do --next index to 16
|
||||
if (t[i][4] and t[i][4]+16 > time) then
|
||||
for i = last_index, _death_event_amt do --next index to 16
|
||||
if (t[i][4] and t[i][4]+_death_event_amt > time) then
|
||||
_table_insert (esta_morte, t[i])
|
||||
end
|
||||
end
|
||||
for i = 1, last_index-1 do --1 to latest index
|
||||
if (t[i][4] and t[i][4]+16 > time) then
|
||||
if (t[i][4] and t[i][4]+_death_event_amt > time) then
|
||||
_table_insert (esta_morte, t[i])
|
||||
end
|
||||
end
|
||||
@@ -2287,11 +2346,11 @@
|
||||
end
|
||||
end
|
||||
|
||||
if (_detalhes.deadlog_limit and #esta_morte > _detalhes.deadlog_limit) then
|
||||
while (#esta_morte > _detalhes.deadlog_limit) do
|
||||
_table_remove (esta_morte, 1)
|
||||
end
|
||||
end
|
||||
--if (_detalhes.deadlog_limit and #esta_morte > _detalhes.deadlog_limit) then
|
||||
-- while (#esta_morte > _detalhes.deadlog_limit) do
|
||||
-- _table_remove (esta_morte, 1)
|
||||
-- end
|
||||
--end
|
||||
|
||||
if (este_jogador.last_cooldown) then
|
||||
local t = {}
|
||||
@@ -2566,19 +2625,26 @@
|
||||
if (_detalhes.is_in_arena and zoneType ~= "arena") then
|
||||
_detalhes:LeftArena()
|
||||
end
|
||||
if (_detalhes.is_in_battleground and zoneType ~= "pvp") then
|
||||
_detalhes.is_in_battleground = nil
|
||||
end
|
||||
|
||||
if (zoneType == "pvp") then
|
||||
if (not _current_combat.pvp) then
|
||||
|
||||
if (_detalhes.debug) then
|
||||
_detalhes:Msg ("(debug) battleground found.")
|
||||
end
|
||||
|
||||
if (_detalhes.debug) then
|
||||
_detalhes:Msg ("(debug) battleground found, starting new combat table.")
|
||||
end
|
||||
|
||||
_detalhes.is_in_battleground = true
|
||||
|
||||
if (_in_combat and not _current_combat.pvp) then
|
||||
_detalhes:SairDoCombate()
|
||||
end
|
||||
|
||||
if (not _in_combat) then
|
||||
_detalhes:EntrarEmCombate()
|
||||
--> sinaliza que esse combate é pvp
|
||||
_current_combat.pvp = true
|
||||
_current_combat.is_pvp = {name = zoneName, zone = ZoneName, mapid = ZoneMapID}
|
||||
_detalhes.listener:RegisterEvent ("CHAT_MSG_BG_SYSTEM_NEUTRAL")
|
||||
_current_combat.is_pvp = {name = zoneName, mapid = ZoneMapID}
|
||||
end
|
||||
|
||||
elseif (zoneType == "arena") then
|
||||
@@ -2727,20 +2793,6 @@
|
||||
_table_wipe (_detalhes.encounter_table)
|
||||
end
|
||||
|
||||
function _detalhes.parser_functions:CHAT_MSG_BG_SYSTEM_NEUTRAL (...)
|
||||
local frase = _select (1, ...)
|
||||
--> reset combat timer
|
||||
if ( (frase:find ("The battle") and frase:find ("has begun!") ) and _current_combat.pvp) then
|
||||
--local tempo_do_combate = _tempo - _current_combat:GetStartTime()
|
||||
local tempo_do_combate = _GetTime() - _current_combat:GetStartTime()
|
||||
|
||||
_detalhes.tabela_overall:SetStartTime (_detalhes.tabela_overall:GetStartTime() + tempo_do_combate)
|
||||
--_current_combat.start_time = _tempo
|
||||
_current_combat:SetStartTime (_GetTime())
|
||||
_detalhes.listener:UnregisterEvent ("CHAT_MSG_BG_SYSTEM_NEUTRAL")
|
||||
end
|
||||
end
|
||||
|
||||
function _detalhes.parser_functions:UNIT_PET (...)
|
||||
_detalhes:SchedulePetUpdate (1)
|
||||
end
|
||||
@@ -2907,8 +2959,24 @@
|
||||
if (_detalhes.debug) then
|
||||
_detalhes:Msg ("(debug) timer is a arena countdown.")
|
||||
end
|
||||
|
||||
elseif (_detalhes.is_in_battleground) then
|
||||
|
||||
local timerType, timeSeconds, totalTime = select (1, ...)
|
||||
|
||||
if (_detalhes.start_battleground) then
|
||||
_detalhes:CancelTimer (_detalhes.start_battleground, true)
|
||||
end
|
||||
|
||||
_detalhes.start_battleground = _detalhes:ScheduleTimer ("CreateBattlegroundSegment", timeSeconds)
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
function _detalhes:CreateBattlegroundSegment()
|
||||
_current_combat:SetStartTime (_GetTime())
|
||||
print ("Battleground has begun.")
|
||||
end
|
||||
|
||||
-- ~load
|
||||
function _detalhes.parser_functions:ADDON_LOADED (...)
|
||||
@@ -3220,6 +3288,7 @@
|
||||
|
||||
--> last events pointer
|
||||
last_events_cache = _current_combat.player_last_events
|
||||
_death_event_amt = _detalhes.deadlog_events
|
||||
|
||||
--> refresh total containers
|
||||
_current_total = _current_combat.totals
|
||||
|
||||
@@ -142,6 +142,8 @@ function DetailsCreateCoolTip()
|
||||
CoolTip.selected_anchor.top = 0
|
||||
CoolTip.selected_anchor.bottom = 0
|
||||
|
||||
CoolTip._default_font = SharedMedia:Fetch ("font", "Friz Quadrata TT")
|
||||
|
||||
--> Create Frames
|
||||
|
||||
--> main frame
|
||||
@@ -667,10 +669,7 @@ function DetailsCreateCoolTip()
|
||||
menuButton.leftText:SetFont (face, size, flags)
|
||||
end
|
||||
else
|
||||
size = leftTextTable [6] or CoolTip.OptionsTable.TextSize or 10
|
||||
face = leftTextTable [7] or [[Fonts\FRIZQT__.TTF]]
|
||||
flags = leftTextTable [8] or CoolTip.OptionsTable.TextShadow or nil
|
||||
menuButton.leftText:SetFont (face, size, flags)
|
||||
menuButton.leftText:SetFont (CoolTip._default_font, leftTextTable [6] or CoolTip.OptionsTable.TextSize or 10, leftTextTable [8] or CoolTip.OptionsTable.TextShadow)
|
||||
end
|
||||
|
||||
local height_mod = CoolTip.OptionsTable.TextHeightMod or 0
|
||||
@@ -744,10 +743,7 @@ function DetailsCreateCoolTip()
|
||||
end
|
||||
|
||||
else
|
||||
size = rightTextTable [6] or CoolTip.OptionsTable.TextSize or 10
|
||||
face = rightTextTable [7] or [[Fonts\FRIZQT__.TTF]]
|
||||
flags = rightTextTable [8] or CoolTip.OptionsTable.TextShadow or nil
|
||||
menuButton.rightText:SetFont (face, size, flags)
|
||||
menuButton.rightText:SetFont (CoolTip._default_font, rightTextTable [6] or CoolTip.OptionsTable.TextSize or 10, rightTextTable [8] or CoolTip.OptionsTable.TextShadow)
|
||||
end
|
||||
|
||||
|
||||
|
||||
@@ -18,17 +18,15 @@ do
|
||||
|
||||
if (not class) then
|
||||
for index, container in _ipairs (_detalhes.tabela_overall) do
|
||||
--if (container._NameIndexTable) then
|
||||
local index = container._NameIndexTable [name]
|
||||
if (index) then
|
||||
local actor = container._ActorTable [index]
|
||||
if (actor.classe ~= "UNGROUPPLAYER") then
|
||||
local left, right, top, bottom = unpack (_detalhes.class_coords [actor.classe] or unknown_class_coords)
|
||||
local r, g, b = unpack (_detalhes.class_colors [actor.classe])
|
||||
return actor.classe, left, right, top, bottom, r or 1, g or 1, b or 1
|
||||
end
|
||||
local index = container._NameIndexTable [name]
|
||||
if (index) then
|
||||
local actor = container._ActorTable [index]
|
||||
if (actor.classe ~= "UNGROUPPLAYER") then
|
||||
local left, right, top, bottom = unpack (_detalhes.class_coords [actor.classe] or unknown_class_coords)
|
||||
local r, g, b = unpack (_detalhes.class_colors [actor.classe])
|
||||
return actor.classe, left, right, top, bottom, r or 1, g or 1, b or 1
|
||||
end
|
||||
--end
|
||||
end
|
||||
end
|
||||
|
||||
return "UNKNOW", 0.75, 1, 0.75, 1, 1, 1, 1, 1
|
||||
|
||||
@@ -877,7 +877,8 @@ local default_profile = {
|
||||
trash_auto_remove = true,
|
||||
|
||||
--> death log
|
||||
deadlog_limit = 12,
|
||||
deadlog_limit = 16,
|
||||
deadlog_events = 16,
|
||||
|
||||
--> report
|
||||
report_lines = 5,
|
||||
|
||||
+44
-16
@@ -4114,6 +4114,30 @@ function window:CreateFrame2()
|
||||
frame2.timetypeDropdown:SetPoint ("left", frame2.timetypeLabel, "right", 2, 0)
|
||||
|
||||
window:CreateLineBackground2 (frame2, "timetypeDropdown", "timetypeLabel", Loc ["STRING_OPTIONS_TIMEMEASURE_DESC"])
|
||||
|
||||
--> death log limit
|
||||
g:NewLabel (frame2, _, "$parentDeathLogLimitLabel", "DeathLogLimitLabel", Loc ["STRING_OPTIONS_DEATHLIMIT"], "GameFontHighlightLeft")
|
||||
--
|
||||
local onSelectDeathLogLimit = function (_, _, limit_amount)
|
||||
_detalhes:SetDeathLogLimit (limit_amount)
|
||||
end
|
||||
local DeathLogLimitOptions = {
|
||||
{value = 16, label = "16 Records", onclick = onSelectDeathLogLimit, icon = [[Interface\WorldStateFrame\ColumnIcon-GraveyardDefend0]]},
|
||||
{value = 32, label = "32 Records", onclick = onSelectDeathLogLimit, icon = [[Interface\WorldStateFrame\ColumnIcon-GraveyardDefend0]]},
|
||||
{value = 45, label = "45 Records", onclick = onSelectDeathLogLimit, icon = [[Interface\WorldStateFrame\ColumnIcon-GraveyardDefend0]]},
|
||||
}
|
||||
local buildDeathLogLimitMenu = function()
|
||||
return DeathLogLimitOptions
|
||||
end
|
||||
local d = g:NewDropDown (frame2, _, "$parentDeathLogLimitDropdown", "DeathLogLimitDropdown", 160, 20, buildDeathLogLimitMenu, nil) -- func, default
|
||||
d.onenter_backdrop = dropdown_backdrop_onenter
|
||||
d.onleave_backdrop = dropdown_backdrop_onleave
|
||||
d:SetBackdrop (dropdown_backdrop)
|
||||
d:SetBackdropColor (unpack (dropdown_backdrop_onleave))
|
||||
|
||||
frame2.DeathLogLimitDropdown:SetPoint ("left", frame2.DeathLogLimitLabel, "right", 2, 0)
|
||||
|
||||
window:CreateLineBackground2 (frame2, "DeathLogLimitDropdown", "DeathLogLimitLabel", Loc ["STRING_OPTIONS_DEATHLIMIT_DESC"])
|
||||
|
||||
--> Erase Chart Data
|
||||
g:NewLabel (frame2, _, "$parentEraseChartDataLabel", "EraseChartDataLabel", Loc ["STRING_OPTIONS_ERASECHARTDATA"], "GameFontHighlightLeft")
|
||||
@@ -4407,16 +4431,17 @@ function window:CreateFrame2()
|
||||
{"fragsPvpLabel", 2},
|
||||
{"EraseChartDataLabel", 3},
|
||||
{"timetypeLabel", 4, true},
|
||||
{"DeathLogLimitLabel", 5, true},
|
||||
|
||||
{"OverallDataLabel", 5, true},
|
||||
{"OverallDataRaidBossLabel", 6},
|
||||
{"OverallDataRaidCleaupLabel", 7},
|
||||
{"OverallDataDungeonBossLabel", 8},
|
||||
{"OverallDataDungeonCleaupLabel", 9},
|
||||
{"OverallDataAllLabel", 10, true},
|
||||
{"OverallNewBossLabel", 11, true},
|
||||
{"OverallNewChallengeLabel", 12},
|
||||
{"OverallOnLogoutLabel", 13},
|
||||
{"DataCollectAnchorLabel", 6, true},
|
||||
{"damageCaptureImage", 7},
|
||||
{"healCaptureImage", 8},
|
||||
{"energyCaptureImage", 9},
|
||||
{"miscCaptureImage", 10},
|
||||
{"auraCaptureImage", 11},
|
||||
{"cloudCaptureLabel", 12, true},
|
||||
|
||||
|
||||
}
|
||||
|
||||
window:arrange_menu (frame2, left_side, x, window.top_start_at)
|
||||
@@ -4424,13 +4449,15 @@ function window:CreateFrame2()
|
||||
local x = window.right_start_at
|
||||
|
||||
local right_side = {
|
||||
{"DataCollectAnchorLabel", 1, true},
|
||||
{"damageCaptureImage", 2},
|
||||
{"healCaptureImage", 3},
|
||||
{"energyCaptureImage", 4},
|
||||
{"miscCaptureImage", 5},
|
||||
{"auraCaptureImage", 6},
|
||||
{"cloudCaptureLabel", 7, true},
|
||||
{"OverallDataLabel", 1, true},
|
||||
{"OverallDataRaidBossLabel", 2},
|
||||
{"OverallDataRaidCleaupLabel", 3},
|
||||
{"OverallDataDungeonBossLabel", 4},
|
||||
{"OverallDataDungeonCleaupLabel", 5},
|
||||
{"OverallDataAllLabel", 6, true},
|
||||
{"OverallNewBossLabel", 7, true},
|
||||
{"OverallNewChallengeLabel", 8},
|
||||
{"OverallOnLogoutLabel", 9},
|
||||
}
|
||||
|
||||
window:arrange_menu (frame2, right_side, x, -90)
|
||||
@@ -10014,6 +10041,7 @@ end --> if not window
|
||||
--> window 2
|
||||
_G.DetailsOptionsWindow2FragsPvpSlider.MyObject:SetValue (_detalhes.only_pvp_frags)
|
||||
_G.DetailsOptionsWindow2TTDropdown.MyObject:Select (_detalhes.time_type)
|
||||
_G.DetailsOptionsWindow2DeathLogLimitDropdown.MyObject:Select (_detalhes.deadlog_events)
|
||||
|
||||
_G.DetailsOptionsWindow2EraseChartDataSlider.MyObject:SetValue (_detalhes.clear_graphic)
|
||||
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
local L = LibStub("AceLocale-3.0"):NewLocale("Details", "zhCN")
|
||||
if not L then return end
|
||||
|
||||
@localization(locale="zhCN", format="lua_additive_table")@
|
||||
Reference in New Issue
Block a user