v9213
Fixed an issue where after reloading, overall data won't show the players nickname. Fixed overkill damage on death log tooltip. Fixed the percent bars for the healing done target on the player breakdown window. Fixed an issue with resource tooltips. And more...
This commit is contained in:
+1
-1
@@ -1,6 +1,6 @@
|
||||
|
||||
|
||||
local dversion = 278
|
||||
local dversion = 282
|
||||
local major, minor = "DetailsFramework-1.0", dversion
|
||||
local DF, oldminor = LibStub:NewLibrary (major, minor)
|
||||
|
||||
|
||||
@@ -58,6 +58,13 @@ function DF:GetRangeValue (minValue, maxValue, percent)
|
||||
return Lerp (minValue, maxValue, percent)
|
||||
end
|
||||
|
||||
function DF:GetColorRangeValue(r1, g1, b1, r2, g2, b2, value)
|
||||
local newR = DF:LerpNorm(r1, r2, value)
|
||||
local newG = DF:LerpNorm(g1, g2, value)
|
||||
local newB = DF:LerpNorm(b1, b2, value)
|
||||
return newR, newG, newB
|
||||
end
|
||||
|
||||
--dot product of two 2D Vectors
|
||||
function DF:GetDotProduct (value1, value2)
|
||||
return (value1.x * value2.x) + (value1.y * value2.y)
|
||||
|
||||
+5
-4
@@ -7368,15 +7368,16 @@ DF.StatusBarFunctions = {
|
||||
self:RunHooksForWidget ("OnHealthMaxChange", self, self.displayedUnit)
|
||||
end
|
||||
|
||||
healthBarMetaFunctions.UpdateHealth = function (self)
|
||||
healthBarMetaFunctions.UpdateHealth = function(self)
|
||||
-- update max health regardless to avoid weird wrong values on UpdateMaxHealth sometimes
|
||||
-- local maxHealth = UnitHealthMax (self.displayedUnit)
|
||||
-- self:SetMinMaxValues (0, maxHealth)
|
||||
-- self.currentHealthMax = maxHealth
|
||||
|
||||
local health = UnitHealth (self.displayedUnit)
|
||||
self.oldHealth = self.currentHealth
|
||||
local health = UnitHealth(self.displayedUnit)
|
||||
self.currentHealth = health
|
||||
PixelUtil.SetStatusBarValue (self, health)
|
||||
PixelUtil.SetStatusBarValue(self, health)
|
||||
|
||||
self:RunHooksForWidget ("OnHealthChange", self, self.displayedUnit)
|
||||
end
|
||||
@@ -8410,7 +8411,7 @@ DF.CastFrameFunctions = {
|
||||
self:SetAlpha (1)
|
||||
self.Icon:SetTexture (texture)
|
||||
self.Icon:Show()
|
||||
self.Text:SetText (text)
|
||||
self.Text:SetText (text or name)
|
||||
|
||||
if (self.Settings.ShowCastTime and self.Settings.CanLazyTick) then
|
||||
self.percentText:Show()
|
||||
|
||||
@@ -1,12 +1,14 @@
|
||||
|
||||
local DF = _G ["DetailsFramework"]
|
||||
if (not DF or not DetailsFrameworkCanLoad) then
|
||||
return
|
||||
end
|
||||
|
||||
|
||||
local DF = DetailsFramework
|
||||
local C_Timer = _G.C_Timer
|
||||
local unpack = _G.unpack
|
||||
|
||||
--make a namespace for schedules
|
||||
DF.Schedules = {}
|
||||
DF.Schedules = DF.Schedules or {}
|
||||
|
||||
--run a scheduled function with its payload
|
||||
local triggerScheduledTick = function(tickerObject)
|
||||
@@ -65,3 +67,7 @@ end
|
||||
function DF.Schedules.SetName(object, name)
|
||||
object.name = name
|
||||
end
|
||||
|
||||
function DF.Schedules.RunNextTick(callback)
|
||||
return DF.Schedules.After(0, callback)
|
||||
end
|
||||
@@ -539,6 +539,7 @@ if (IS_WOW_PROJECT_NOT_MAINLINE) then
|
||||
DF.CooldownsBySpec[65][5588] = 5 --hammer of justice Rank 2
|
||||
DF.CooldownsBySpec[65][5589] = 5 --hammer of justice Rank 3
|
||||
DF.CooldownsBySpec[65][10308] = 5 --hammer of justice Rank 4
|
||||
DF.CooldownsBySpec[65][10326] = 5 --Turn Evil
|
||||
DF.CooldownsBySpec[65][20729] = 3 --blessing of sacrifice Rank 2
|
||||
DF.CooldownsBySpec[65][27147] = 3 --blessing of sacrifice Rank 3
|
||||
DF.CooldownsBySpec[65][27148] = 3 --blessing of sacrifice Rank 4
|
||||
@@ -557,6 +558,7 @@ if (IS_WOW_PROJECT_NOT_MAINLINE) then
|
||||
DF.CooldownsBySpec[66][5588] = 5 --hammer of justice Rank 2
|
||||
DF.CooldownsBySpec[66][5589] = 5 --hammer of justice Rank 3
|
||||
DF.CooldownsBySpec[66][10308] = 5 --hammer of justice Rank 4
|
||||
DF.CooldownsBySpec[66][10326] = 5 --Turn Evil
|
||||
DF.CooldownsBySpec[66][5599] = 3 --blessing of protection Rank 2
|
||||
DF.CooldownsBySpec[66][10278] = 3 --blessing of protection Rank 3
|
||||
|
||||
@@ -570,6 +572,7 @@ if (IS_WOW_PROJECT_NOT_MAINLINE) then
|
||||
DF.CooldownsBySpec[70][5588] = 5 --hammer of justice Rank 2
|
||||
DF.CooldownsBySpec[70][5589] = 5 --hammer of justice Rank 3
|
||||
DF.CooldownsBySpec[70][10308] = 5 --hammer of justice Rank 4
|
||||
DF.CooldownsBySpec[70][10326] = 5 --Turn Evil
|
||||
DF.CooldownsBySpec[70][5599] = 3 --blessing of protection Rank 2
|
||||
DF.CooldownsBySpec[70][10278] = 3 --blessing of protection Rank 3
|
||||
DF.CooldownsBySpec[70][20729] = 3 --blessing of sacrifice Rank 2
|
||||
@@ -1055,6 +1058,7 @@ if (IS_WOW_PROJECT_NOT_MAINLINE) then
|
||||
DF.CrowdControlSpells[5588] = "PALADIN" --hammer of justice Rank 2
|
||||
DF.CrowdControlSpells[5589] = "PALADIN" --hammer of justice Rank 3
|
||||
DF.CrowdControlSpells[10308] = "PALADIN" --hammer of justice Rank 4
|
||||
DF.CrowdControlSpells[10326] = "PALADIN" --Turn Evil
|
||||
|
||||
DF.CrowdControlSpells[8124] = "PRIEST" --psychic scream Rank 2
|
||||
DF.CrowdControlSpells[10888] = "PRIEST" --psychic scream Rank 3
|
||||
|
||||
@@ -6,9 +6,9 @@
|
||||
|
||||
local version, build, date, tocversion = GetBuildInfo()
|
||||
|
||||
_detalhes.build_counter = 9108
|
||||
_detalhes.alpha_build_counter = 9108 --if this is higher than the regular counter, use it instead
|
||||
_detalhes.bcc_counter = 29
|
||||
_detalhes.build_counter = 9213
|
||||
_detalhes.alpha_build_counter = 9213 --if this is higher than the regular counter, use it instead
|
||||
_detalhes.bcc_counter = 30
|
||||
_detalhes.dont_open_news = true
|
||||
_detalhes.game_version = version
|
||||
_detalhes.userversion = version .. _detalhes.build_counter
|
||||
@@ -33,6 +33,13 @@ do
|
||||
local Loc = _G.LibStub("AceLocale-3.0"):GetLocale( "Details" )
|
||||
|
||||
local news = {
|
||||
|
||||
{"v9.1.5.9213.145", "December 9th, 2021"},
|
||||
"Fixed an issue where after reloading, overall data won't show the players nickname.",
|
||||
"Fixed overkill damage on death log tooltip.",
|
||||
"Fixed the percent bars for the healing done target on the player breakdown window.",
|
||||
"Fixed an issue with resource tooltips.",
|
||||
|
||||
{"v9.1.5.9108.145", "November 02th, 2021"},
|
||||
"Necrotic Wake: weapons damage does not count anymore for the player which uses it.",
|
||||
"Necrotic Wake: a new 'fake player' is shown showing the damage done of all weapons during combat.",
|
||||
|
||||
@@ -5306,6 +5306,8 @@ end
|
||||
shadow.end_time = time()
|
||||
end
|
||||
|
||||
shadow.displayName = actor.displayName or actor.nome
|
||||
|
||||
shadow.boss_fight_component = actor.boss_fight_component or shadow.boss_fight_component
|
||||
shadow.fight_component = actor.fight_component or shadow.fight_component
|
||||
shadow.grupo = actor.grupo or shadow.grupo
|
||||
|
||||
+16
-16
@@ -1940,7 +1940,7 @@ function atributo_heal:MontaInfoHealingDone()
|
||||
barra.on_focus = false
|
||||
end
|
||||
|
||||
self:FocusLock (barra, tabela[1])
|
||||
self:FocusLock(barra, tabela[1])
|
||||
|
||||
barra.other_actor = tabela [6]
|
||||
|
||||
@@ -1967,19 +1967,17 @@ function atributo_heal:MontaInfoHealingDone()
|
||||
end
|
||||
|
||||
--> TOP CURADOS
|
||||
local meus_inimigos = {}
|
||||
local healedTargets = {}
|
||||
tabela = self.targets
|
||||
for target_name, amount in _pairs (tabela) do
|
||||
_table_insert (meus_inimigos, {target_name, amount, amount / total*100})
|
||||
_table_insert (healedTargets, {target_name, amount, amount / total*100})
|
||||
end
|
||||
_table_sort (meus_inimigos, _detalhes.Sort2)
|
||||
|
||||
local amt_alvos = #meus_inimigos
|
||||
gump:JI_AtualizaContainerAlvos (amt_alvos)
|
||||
|
||||
local max_inimigos = meus_inimigos[1] and meus_inimigos[1][2] or 0
|
||||
|
||||
for index, tabela in _ipairs (meus_inimigos) do
|
||||
_table_sort(healedTargets, _detalhes.Sort2)
|
||||
|
||||
gump:JI_AtualizaContainerAlvos(#healedTargets)
|
||||
local topHealingDone = healedTargets[1] and healedTargets[1][2]
|
||||
|
||||
for index, tabela in _ipairs (healedTargets) do
|
||||
|
||||
local barra = info.barras2 [index]
|
||||
|
||||
@@ -1988,10 +1986,12 @@ function atributo_heal:MontaInfoHealingDone()
|
||||
barra.textura:SetStatusBarColor (1, 1, 1, 1)
|
||||
end
|
||||
|
||||
local healingDone = tabela[2]
|
||||
|
||||
if (index == 1) then
|
||||
barra.textura:SetValue (100)
|
||||
barra.textura:SetValue(100)
|
||||
else
|
||||
barra.textura:SetValue (tabela[2]/max_*100)
|
||||
barra.textura:SetValue(healingDone / topHealingDone * 100)
|
||||
end
|
||||
|
||||
local target_actor = instancia.showing (2, tabela[1])
|
||||
@@ -2004,12 +2004,12 @@ function atributo_heal:MontaInfoHealingDone()
|
||||
end
|
||||
|
||||
barra.lineText1:SetText (index .. ". " .. _detalhes:GetOnlyName (tabela[1]))
|
||||
barra.textura:SetStatusBarColor (1, 1, 1, 1)
|
||||
barra.textura:SetStatusBarColor(1, 1, 1, 1)
|
||||
|
||||
if (info.sub_atributo == 2) then
|
||||
barra.lineText4:SetText (_detalhes:comma_value (_math_floor (tabela[2]/meu_tempo)) .." (" .. _cstr ("%.1f", tabela[3]) .. "%)")
|
||||
barra.lineText4:SetText (_detalhes:comma_value (_math_floor (healingDone/meu_tempo)) .." (" .. _cstr ("%.1f", tabela[3]) .. "%)")
|
||||
else
|
||||
barra.lineText4:SetText (SelectedToKFunction (_, tabela[2]) .. " (" .. _cstr ("%.1f", tabela[3]) .. "%)")
|
||||
barra.lineText4:SetText (SelectedToKFunction (_, healingDone) .. " (" .. _cstr ("%.1f", tabela[3]) .. "%)")
|
||||
end
|
||||
|
||||
barra.minha_tabela = self
|
||||
|
||||
@@ -1344,8 +1344,8 @@ function atributo_energy:MontaTooltipAlvos (esta_barra, index)
|
||||
end
|
||||
|
||||
local spellname, _, spellicon = _GetSpellInfo (spell [1])
|
||||
GameTooltip:AddDoubleLine (spellname .. ": ", _detalhes:comma_value (spell [2]) .. " (" .. _cstr ("%.1f", (spell [2] / total_regenerado) * 100).."%)", 1, 1, 1, 1, 1, 1)
|
||||
GameTooltip:AddTexture (icone_magia)
|
||||
GameTooltip:AddDoubleLine(spellname .. ": ", _detalhes:comma_value (spell [2]) .. " (" .. _cstr ("%.1f", (spell [2] / total_regenerado) * 100).."%)", 1, 1, 1, 1, 1, 1)
|
||||
GameTooltip:AddTexture(spellicon)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -245,13 +245,16 @@ function _detalhes:ToolTipDead (instancia, morte, esta_barra, keydown)
|
||||
local critOrCrush = critical .. crushing
|
||||
|
||||
if (overkill > 0) then
|
||||
--check the type of overkill that should be shown
|
||||
--if show_totalhitdamage_on_overkill is true it'll show the total damage of the hit
|
||||
--if false it shows the total damage of the hit minus the overkill
|
||||
if (not _detalhes.show_totalhitdamage_on_overkill) then
|
||||
amount = amount - overkill
|
||||
end
|
||||
|
||||
|
||||
--> deprecated as the parser now removes the overkill damage from total damage
|
||||
--> this should now sum the overkill from [10] with the damage from [3]
|
||||
--check the type of overkill that should be shown
|
||||
--if show_totalhitdamage_on_overkill is true it'll show the total damage of the hit
|
||||
--if false it shows the total damage of the hit minus the overkill
|
||||
--if (not _detalhes.show_totalhitdamage_on_overkill) then
|
||||
-- amount = amount - overkill
|
||||
--end
|
||||
|
||||
overkill = " (" .. _detalhes:ToK (overkill) .. " |cFFFF8800overkill|r)"
|
||||
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s |cFFFFFF00" .. spellname .. "|r (|cFFC6B0D9" .. source .. "|r)", "-" .. _detalhes:ToK (amount) .. critOrCrush .. overkill .. " (" .. hp .. "%)", 1, "white", "white")
|
||||
else
|
||||
|
||||
@@ -113,37 +113,29 @@ function historico:adicionar_overall (tabela)
|
||||
_detalhes.tabela_overall.overall_enemy_name = "-- x -- x --"
|
||||
end
|
||||
end
|
||||
|
||||
--
|
||||
if (_detalhes.tabela_overall.start_time == 0) then
|
||||
--print ("start_time == 0 NO!")
|
||||
_detalhes.tabela_overall:SetStartTime (tabela.start_time)
|
||||
_detalhes.tabela_overall:SetEndTime (tabela.end_time)
|
||||
else
|
||||
--print ("start_time ~= 0 OKAY", tabela.start_time, _detalhes.tabela_overall:GetCombatTime(), tabela.start_time - _detalhes.tabela_overall:GetCombatTime())
|
||||
_detalhes.tabela_overall:SetStartTime (tabela.start_time - _detalhes.tabela_overall:GetCombatTime())
|
||||
_detalhes.tabela_overall:SetEndTime (tabela.end_time)
|
||||
end
|
||||
|
||||
if (_detalhes.tabela_overall.data_inicio == 0) then
|
||||
_detalhes.tabela_overall.data_inicio = _detalhes.tabela_vigente.data_inicio or 0
|
||||
end
|
||||
--
|
||||
|
||||
|
||||
if (_detalhes.tabela_overall.start_time == 0) then
|
||||
_detalhes.tabela_overall:SetStartTime (tabela.start_time)
|
||||
_detalhes.tabela_overall:SetEndTime (tabela.end_time)
|
||||
else
|
||||
_detalhes.tabela_overall:SetStartTime (tabela.start_time - _detalhes.tabela_overall:GetCombatTime())
|
||||
_detalhes.tabela_overall:SetEndTime (tabela.end_time)
|
||||
end
|
||||
|
||||
if (_detalhes.tabela_overall.data_inicio == 0) then
|
||||
_detalhes.tabela_overall.data_inicio = _detalhes.tabela_vigente.data_inicio or 0
|
||||
end
|
||||
|
||||
_detalhes.tabela_overall:seta_data (_detalhes._detalhes_props.DATA_TYPE_END)
|
||||
|
||||
_detalhes:ClockPluginTickOnSegment()
|
||||
|
||||
|
||||
for id, instance in _detalhes:ListInstances() do
|
||||
if (instance:IsEnabled()) then
|
||||
if (instance:GetSegment() == -1) then
|
||||
instance:ForceRefresh()
|
||||
--instance:RefreshMainWindow (true)
|
||||
--print ("isntance", id, "overall updated.")
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function _detalhes:ScheduleAddCombatToOverall (combat) --deprecated (15/03/2019)
|
||||
|
||||
+53
-9
@@ -252,7 +252,9 @@
|
||||
local TBC_PrayerOfMendingCache = {}
|
||||
local TBC_EarthShieldCache = {}
|
||||
local TBC_LifeBloomLatestHeal
|
||||
local TBC_JudgementOfLightCache = {}
|
||||
local TBC_JudgementOfLightCache = {
|
||||
_damageCache = {}
|
||||
}
|
||||
|
||||
--expose the override spells table to external scripts
|
||||
_detalhes.OverridedSpellIds = override_spellId
|
||||
@@ -288,7 +290,6 @@
|
||||
--> restoration shaman spirit link totem
|
||||
local SPELLID_SHAMAN_SLT = 98021
|
||||
--> holy paladin light of the martyr
|
||||
local SPELLID_PALADIN_LIGHTMARTYR = 196917
|
||||
--> druid kyrian bound spirits
|
||||
local SPELLID_KYRIAN_DRUID = 326434
|
||||
--> druid kyrian bound damage, heal
|
||||
@@ -326,7 +327,6 @@
|
||||
--> spells with special treatment
|
||||
local special_damage_spells = {
|
||||
[SPELLID_SHAMAN_SLT] = true, --> Spirit Link Toten
|
||||
[SPELLID_PALADIN_LIGHTMARTYR] = true, --> Light of the Martyr
|
||||
[SPELLID_MONK_STAGGER] = true, --> Stagger
|
||||
[315161] = true, --> Eye of Corruption --REMOVE ON 9.0
|
||||
[315197] = true, --> Thing From Beyond --REMOVE ON 9.0
|
||||
@@ -814,11 +814,19 @@
|
||||
return parser:SLT_damage (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, spelltype, amount, overkill, school, resisted, blocked, absorbed, critical, glacing, crushing, isoffhand)
|
||||
|
||||
--> Light of the Martyr - paladin spell which causes damage to the caster it self
|
||||
elseif (spellid == SPELLID_PALADIN_LIGHTMARTYR) then -- or spellid == 183998 < healing part
|
||||
elseif (spellid == 196917) then -- or spellid == 183998 < healing part
|
||||
return parser:LOTM_damage (token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, spellid, spellname, spelltype, amount, overkill, school, resisted, blocked, absorbed, critical, glacing, crushing, isoffhand)
|
||||
end
|
||||
--end
|
||||
|
||||
if (isTBC) then
|
||||
--is the target an enemy with judgement of light?
|
||||
if (TBC_JudgementOfLightCache[alvo_name]) then
|
||||
--store the player name which just landed a damage
|
||||
TBC_JudgementOfLightCache._damageCache[who_name] = {time, alvo_name}
|
||||
end
|
||||
end
|
||||
|
||||
------------------------------------------------------------------------------------------------
|
||||
--> check if need start an combat
|
||||
|
||||
@@ -2085,11 +2093,23 @@
|
||||
TBC_LifeBloomLatestHeal = cura_efetiva
|
||||
return
|
||||
|
||||
elseif (spellid == 27163) then --Judgement of Light (paladin)
|
||||
local sourceData = TBC_JudgementOfLightCache[who_name]
|
||||
if (sourceData) then
|
||||
who_serial, who_name, who_flags = unpack(sourceData)
|
||||
TBC_JudgementOfLightCache[who_name] = nil
|
||||
elseif (spellid == 27163) then --Judgement of Light (paladin)
|
||||
--check if the hit was landed in the same cleu tick
|
||||
|
||||
local hitCache = TBC_JudgementOfLightCache._damageCache[who_name]
|
||||
if (hitCache) then
|
||||
local timeLanded = hitCache[1]
|
||||
local targetHit = hitCache[2]
|
||||
|
||||
if (timeLanded and timeLanded == time) then
|
||||
local sourceData = TBC_JudgementOfLightCache[targetHit]
|
||||
if (sourceData) then
|
||||
--change the source of the healing
|
||||
who_serial, who_name, who_flags = unpack(sourceData)
|
||||
--erase the hit time information
|
||||
TBC_JudgementOfLightCache._damageCache[who_name] = nil
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
@@ -2443,6 +2463,13 @@
|
||||
elseif (spellid == SPELLID_VENTYR_TAME_GARGOYLE) then --ventyr tame gargoyle on halls of atonement --remove on 10.0
|
||||
_detalhes.tabela_pets:Adicionar(alvo_serial, alvo_name, alvo_flags, who_serial, who_name, 0x00000417)
|
||||
end
|
||||
|
||||
if (isTBC) then --buff applied
|
||||
if (spellid == 27162) then --Judgement Of Light
|
||||
--which player applied the judgement of light on this mob
|
||||
TBC_JudgementOfLightCache[alvo_name] = {who_serial, who_name, who_flags}
|
||||
end
|
||||
end
|
||||
|
||||
------------------------------------------------------------------------------------------------
|
||||
--> spell reflection
|
||||
@@ -2711,6 +2738,13 @@
|
||||
bargastBuffs[alvo_serial] = (bargastBuffs[alvo_serial] or 0) + 1
|
||||
end
|
||||
|
||||
if (isTBC) then --buff refresh
|
||||
if (spellid == 27162) then --Judgement Of Light
|
||||
--which player applied the judgement of light on this mob
|
||||
TBC_JudgementOfLightCache[alvo_name] = {who_serial, who_name, who_flags}
|
||||
end
|
||||
end
|
||||
|
||||
if (_in_combat) then
|
||||
------------------------------------------------------------------------------------------------
|
||||
--> buff uptime
|
||||
@@ -2875,6 +2909,12 @@
|
||||
local enemyName = GetSpellInfo(315161)
|
||||
who_serial, who_name, who_flags = "", enemyName, 0xa48
|
||||
end
|
||||
|
||||
if (isTBC) then --buff removed
|
||||
if (spellid == 27162) then --Judgement Of Light
|
||||
TBC_JudgementOfLightCache[alvo_name] = nil
|
||||
end
|
||||
end
|
||||
|
||||
------------------------------------------------------------------------------------------------
|
||||
--> spell reflection
|
||||
@@ -5068,6 +5108,10 @@ local SPELL_POWER_PAIN = SPELL_POWER_PAIN or (PowerEnum and PowerEnum.Pain) or 1
|
||||
_detalhes:Msg ("(debug) running scheduled events after combat end.")
|
||||
end
|
||||
|
||||
TBC_JudgementOfLightCache = {
|
||||
_damageCache = {}
|
||||
}
|
||||
|
||||
--when the user requested data from the storage but is in combat lockdown
|
||||
if (_detalhes.schedule_storage_load) then
|
||||
_detalhes.schedule_storage_load = nil
|
||||
|
||||
@@ -5616,10 +5616,9 @@ local function CriaTexturaBarra (instancia, barra)
|
||||
end
|
||||
|
||||
barra.lineText1 = barra:CreateFontString (nil, "OVERLAY", "GameFontHighlightSmall")
|
||||
barra.lineText1:SetPoint ("LEFT", barra.textura, "LEFT", CONST_BAR_HEIGHT + 6, 0)
|
||||
barra.lineText1:SetPoint ("LEFT", barra.icone, "RIGHT", 2, 0)
|
||||
barra.lineText1:SetJustifyH ("LEFT")
|
||||
barra.lineText1:SetTextColor (1,1,1,1)
|
||||
|
||||
barra.lineText1:SetNonSpaceWrap (true)
|
||||
barra.lineText1:SetWordWrap (false)
|
||||
|
||||
@@ -5808,7 +5807,7 @@ function gump:CriaNovaBarraInfo1 (instancia, index)
|
||||
local y = (index-1) * (CONST_BAR_HEIGHT + 1)
|
||||
y = y*-1 --> baixo
|
||||
|
||||
esta_barra:SetPoint ("LEFT", janela, "LEFT")
|
||||
esta_barra:SetPoint ("LEFT", janela, "LEFT", CONST_BAR_HEIGHT, 0)
|
||||
esta_barra:SetPoint ("RIGHT", janela, "RIGHT")
|
||||
esta_barra:SetPoint ("TOP", janela, "TOP", 0, y)
|
||||
esta_barra:SetFrameLevel (janela:GetFrameLevel() + 1)
|
||||
@@ -5828,21 +5827,21 @@ function gump:CriaNovaBarraInfo1 (instancia, index)
|
||||
esta_barra.targets:SetScript ("OnEnter", target_on_enter)
|
||||
esta_barra.targets:SetScript ("OnLeave", target_on_leave)
|
||||
|
||||
CriaTexturaBarra (instancia, esta_barra)
|
||||
esta_barra.icone = esta_barra:CreateTexture (nil, "OVERLAY")
|
||||
esta_barra.icone:SetWidth (CONST_BAR_HEIGHT)
|
||||
esta_barra.icone:SetHeight (CONST_BAR_HEIGHT)
|
||||
esta_barra.icone:SetPoint ("RIGHT", esta_barra, "LEFT", 0, 0)
|
||||
|
||||
CriaTexturaBarra(instancia, esta_barra)
|
||||
|
||||
--> icone
|
||||
esta_barra.miniframe = CreateFrame ("frame", nil, esta_barra, "BackdropTemplate")
|
||||
esta_barra.miniframe:SetSize (CONST_BAR_HEIGHT-2, CONST_BAR_HEIGHT-2)
|
||||
esta_barra.miniframe:SetPoint ("RIGHT", esta_barra.textura, "LEFT", CONST_BAR_HEIGHT + 2, 0)
|
||||
esta_barra.miniframe:SetPoint ("left", esta_barra, "left", 0, 0)
|
||||
|
||||
esta_barra.miniframe:SetScript ("OnEnter", miniframe_func_on_enter)
|
||||
esta_barra.miniframe:SetScript ("OnLeave", miniframe_func_on_leave)
|
||||
|
||||
esta_barra.icone = esta_barra:CreateTexture (nil, "OVERLAY")
|
||||
esta_barra.icone:SetWidth (CONST_BAR_HEIGHT)
|
||||
esta_barra.icone:SetHeight (CONST_BAR_HEIGHT)
|
||||
esta_barra.icone:SetPoint ("RIGHT", esta_barra.textura, "LEFT", CONST_BAR_HEIGHT + 2, 0)
|
||||
|
||||
|
||||
esta_barra:SetAlpha(1)
|
||||
esta_barra.icone:SetAlpha (1)
|
||||
|
||||
@@ -5858,7 +5857,7 @@ function gump:CriaNovaBarraInfo1 (instancia, index)
|
||||
return esta_barra
|
||||
end
|
||||
|
||||
function gump:CriaNovaBarraInfo2 (instancia, index)
|
||||
function gump:CriaNovaBarraInfo2(instancia, index)
|
||||
|
||||
if (_detalhes.playerDetailWindow.barras2 [index]) then
|
||||
print ("erro a barra "..index.." ja existe na janela de detalhes...")
|
||||
@@ -5873,28 +5872,28 @@ function gump:CriaNovaBarraInfo2 (instancia, index)
|
||||
local y = (index-1) * (CONST_TARGET_HEIGHT + 1)
|
||||
y = y*-1 --> baixo
|
||||
|
||||
esta_barra:SetPoint ("LEFT", janela, "LEFT")
|
||||
esta_barra:SetPoint ("RIGHT", janela, "RIGHT")
|
||||
esta_barra:SetPoint ("TOP", janela, "TOP", 0, y)
|
||||
esta_barra:SetPoint("LEFT", janela, "LEFT", CONST_TARGET_HEIGHT, 0)
|
||||
esta_barra:SetPoint("RIGHT", janela, "RIGHT", 0, 0)
|
||||
esta_barra:SetPoint("TOP", janela, "TOP", 0, y)
|
||||
esta_barra:SetFrameLevel (janela:GetFrameLevel() + 1)
|
||||
|
||||
esta_barra:EnableMouse (true)
|
||||
esta_barra:RegisterForClicks ("LeftButtonDown","RightButtonUp")
|
||||
|
||||
CriaTexturaBarra (instancia, esta_barra)
|
||||
|
||||
--> icone
|
||||
esta_barra.icone = esta_barra:CreateTexture (nil, "OVERLAY")
|
||||
esta_barra.icone:SetWidth (CONST_TARGET_HEIGHT)
|
||||
esta_barra.icone:SetHeight (CONST_TARGET_HEIGHT)
|
||||
esta_barra.icone:SetPoint ("RIGHT", esta_barra.textura, "LEFT", CONST_TARGET_HEIGHT + 2, 0)
|
||||
esta_barra.icone = esta_barra:CreateTexture(nil, "OVERLAY")
|
||||
esta_barra.icone:SetWidth(CONST_TARGET_HEIGHT)
|
||||
esta_barra.icone:SetHeight(CONST_TARGET_HEIGHT)
|
||||
esta_barra.icone:SetPoint("RIGHT", esta_barra, "LEFT", 0, 0)
|
||||
|
||||
CriaTexturaBarra(instancia, esta_barra)
|
||||
|
||||
esta_barra:SetAlpha (ALPHA_BLEND_AMOUNT)
|
||||
esta_barra.icone:SetAlpha (1)
|
||||
esta_barra:SetAlpha(ALPHA_BLEND_AMOUNT)
|
||||
esta_barra.icone:SetAlpha(1)
|
||||
|
||||
esta_barra.isAlvo = true
|
||||
|
||||
SetBarraScripts (esta_barra, instancia, index)
|
||||
SetBarraScripts(esta_barra, instancia, index)
|
||||
|
||||
info.barras2 [index] = esta_barra --> barra adicionada
|
||||
|
||||
|
||||
@@ -31,6 +31,7 @@
|
||||
if (playerObject) then
|
||||
local line = self:GetLine(i)
|
||||
line.playerObject = playerObject
|
||||
line.index = index
|
||||
line:UpdateLine(topResult)
|
||||
end
|
||||
end
|
||||
@@ -111,6 +112,7 @@
|
||||
|
||||
--set the player name
|
||||
self.playerName:SetText(Details:GetOnlyName(self.playerObject.nome))
|
||||
self.rankText:SetText(self.index)
|
||||
|
||||
--set the player class name
|
||||
self.className:SetText(string.lower(_G.UnitClass(self.playerObject.nome) or self.playerObject:Class()))
|
||||
@@ -151,6 +153,10 @@
|
||||
className.textcolor = {.95, .8, .2, 0}
|
||||
className.textsize = 9
|
||||
|
||||
local rankText = DF:CreateLabel(line, "", "GameFontNormal")
|
||||
rankText.textcolor = {.3, .3, .3, .7}
|
||||
rankText.textsize = 13
|
||||
|
||||
local totalStatusBar = CreateFrame("statusbar", nil, line)
|
||||
totalStatusBar:SetSize(scrollbox_size[1]-19-player_line_height, 4)
|
||||
totalStatusBar:SetMinMaxValues(0, 100)
|
||||
@@ -160,15 +166,16 @@
|
||||
--setup anchors
|
||||
specIcon:SetPoint("topleft", line, "topleft", 0, 0)
|
||||
roleIcon:SetPoint("topleft", specIcon, "topright", 2, 0)
|
||||
--playerName:SetPoint("left", roleIcon, "right", 2, 0)
|
||||
playerName:SetPoint("topleft", specIcon, "topright", 2, -1)
|
||||
playerName:SetPoint("topleft", specIcon, "topright", 2, -3)
|
||||
className:SetPoint("topleft", roleIcon, "bottomleft", 0, -2)
|
||||
rankText:SetPoint("right", line, "right", -2, 0)
|
||||
totalStatusBar:SetPoint("bottomleft", specIcon, "bottomright", 0, 0)
|
||||
|
||||
line.specIcon = specIcon
|
||||
line.roleIcon = roleIcon
|
||||
line.playerName = playerName
|
||||
line.className = className
|
||||
line.rankText = rankText
|
||||
line.totalStatusBar = totalStatusBar
|
||||
|
||||
line.UpdateLine = updatePlayerLine
|
||||
@@ -207,13 +214,12 @@
|
||||
DRUID = 11,
|
||||
DEMONHUNTER = 12,
|
||||
}
|
||||
|
||||
|
||||
--get the player list from the segment and build a table compatible with the scroll box
|
||||
function breakdownWindowPlayerList.BuildPlayerList()
|
||||
local segment = Details:GetCombatFromBreakdownWindow()
|
||||
local playerTable = {}
|
||||
if (segment) then
|
||||
--need to know if this is showing damage or heal
|
||||
local displayType = Details:GetDisplayTypeFromBreakdownWindow()
|
||||
local containerType = displayType == 1 and DETAILS_ATTRIBUTE_DAMAGE or DETAILS_ATTRIBUTE_HEAL
|
||||
local container = segment:GetContainer(containerType)
|
||||
@@ -226,25 +232,28 @@
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
table.sort (playerTable, DF.SortOrder3)
|
||||
|
||||
|
||||
table.sort(playerTable, DF.SortOrder3)
|
||||
|
||||
local resultTable = {}
|
||||
for i = 1, #playerTable do
|
||||
resultTable [#resultTable+1] = playerTable[i][1]
|
||||
resultTable[#resultTable+1] = playerTable[i][1]
|
||||
end
|
||||
|
||||
|
||||
return resultTable
|
||||
end
|
||||
|
||||
|
||||
local updatePlayerList = function()
|
||||
local playerList = breakdownWindowPlayerList.BuildPlayerList()
|
||||
playerScroll:SetData (playerList)
|
||||
playerScroll:Refresh()
|
||||
playerScroll:Show()
|
||||
end
|
||||
|
||||
function Details:UpdateBreakdownPlayerList()
|
||||
--run the update on the next tick
|
||||
C_Timer.After(0, function()
|
||||
local playerList = breakdownWindowPlayerList.BuildPlayerList()
|
||||
playerScroll:SetData (playerList)
|
||||
playerScroll:Refresh()
|
||||
playerScroll:Show()
|
||||
end)
|
||||
C_Timer.After(0, updatePlayerList)
|
||||
--DF.Schedules.RunNextTick(updatePlayerList)
|
||||
end
|
||||
|
||||
f:HookScript("OnShow", function()
|
||||
|
||||
+13
-2
@@ -130,9 +130,20 @@ function Details:StartMeUp() --I'll never stop!
|
||||
end
|
||||
|
||||
function self:RefreshAfterStartup()
|
||||
|
||||
|
||||
--repair nicknames
|
||||
local currentCombat = Details:GetCurrentCombat()
|
||||
local containerDamage = currentCombat:GetContainer(DETAILS_ATTRIBUTE_DAMAGE)
|
||||
for _, actorObject in containerDamage:ListActors() do
|
||||
--get the actor nickname
|
||||
local nickname = Details:GetNickname(actorObject:Name(), false, true)
|
||||
if (nickname) then
|
||||
actorObject.displayName = nickname
|
||||
end
|
||||
end
|
||||
|
||||
self:RefreshMainWindow(-1, true)
|
||||
|
||||
|
||||
local lower_instance = _detalhes:GetLowerInstanceNumber()
|
||||
|
||||
for index = 1, #self.tabela_instancias do
|
||||
|
||||
Reference in New Issue
Block a user