- Added a new panel to open the Chart after a mythic dungeon.

- Improvements on Encounter Details plugin.
This commit is contained in:
Tercio
2018-09-11 19:57:17 -03:00
parent 3f18a99d42
commit ed8aaee352
11 changed files with 298 additions and 276 deletions
+4 -3
View File
File diff suppressed because one or more lines are too long
+1
View File
@@ -277,6 +277,7 @@ function _detalhes:ToolTipDead (instancia, morte, esta_barra, keydown)
lastcooldown = event
elseif (evtype == 4) then
--> debuff
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s [x" .. amount .. "] " .. spellname .. " (" .. source .. ")", "debuff (" .. hp .. "%)", 1, "white", "white")
GameCooltip:AddIcon (spellicon)
GameCooltip:AddStatusBar (100, 1, "purple", true)
+17
View File
@@ -1851,6 +1851,19 @@ inspect_frame:SetScript ("OnEvent", function (self, event, ...)
ilvl_core:ScheduleTimer ("CalcItemLevel", 4, t)
ilvl_core:ScheduleTimer ("CalcItemLevel", 8, t)
end
else
if (IsInRaid()) then
--get the unitID
local serial = ...
if (serial and type (serial) == "string") then
for i = 1, GetNumGroupMembers() do
if (UnitGUID ("raid" .. i) == serial) then
ilvl_core:ScheduleTimer ("CalcItemLevel", 2, {"raid" .. i, serial})
ilvl_core:ScheduleTimer ("CalcItemLevel", 4, {"raid" .. i, serial})
end
end
end
end
end
end)
@@ -2119,6 +2132,10 @@ if (LibGroupInSpecT) then
end
_detalhes.cached_talents [guid] = talents
if (_detalhes.debug) then
_detalhes:Msg ("(debug) received GroupInSpecT_Update from user", guid)
end
--> update spec
if (info.global_spec_id and info.global_spec_id ~= 0) then
if (not _detalhes.class_specs_coords [info.global_spec_id]) then
+66 -51
View File
@@ -6,10 +6,12 @@
--local pointer to details object
local Details = _G._detalhes
local debugmode = false
local verbosemode = false
local debugmode = false --print debug lines
local verbosemode = false --auto open the chart panel
local _
local Loc = LibStub ("AceLocale-3.0"):GetLocale ( "Details" )
--constants
local CONST_USE_PLAYER_EDPS = false
@@ -252,12 +254,12 @@ function mythicDungeonCharts:OnEndMythicDungeon()
mythicDungeonCharts:Debug ("OnEndMythicDungeon() player wasn't inside the dungeon.")
return
end
mythicDungeonCharts:Debug ("Dungeon ended successfully, chart data capture stopped, scheduling to open the window.")
--> the run is valid, schedule to open the chart window
_detalhes.mythic_plus.delay_to_show_graphic = 20
C_Timer.After (_detalhes.mythic_plus.delay_to_show_graphic or 20, mythicDungeonCharts.ShowChart)
_detalhes.mythic_plus.delay_to_show_graphic = 5
C_Timer.After (_detalhes.mythic_plus.delay_to_show_graphic or 5, mythicDungeonCharts.ShowReadyPanel)
if (verbosemode) then
mythicDungeonCharts:Debug ("OnEndMythicDungeon() success!")
@@ -275,14 +277,70 @@ mythicDungeonCharts:RegisterEvent ("COMBAT_MYTHICDUNGEON_END", "OnEndMythicDunge
mythicDungeonCharts:RegisterEvent ("COMBAT_BOSS_DEFEATED", "OnBossDefeated")
-- /run _G.DetailsMythicDungeonChartHandler.ShowChart(); DetailsMythicDungeonChartFrame.ShowChartFrame()
-- /run _G.DetailsMythicDungeonChartHandler.ShowReadyPanel()
--show a small panel telling the chart is ready to show
function mythicDungeonCharts.ShowReadyPanel()
--check if is enabled
if (not _detalhes.mythic_plus.show_damage_graphic) then
return
end
--create the panel
if (not mythicDungeonCharts.ReadyFrame) then
mythicDungeonCharts.ReadyFrame = CreateFrame ("frame", "DetailsMythicDungeoReadyFrame", UIParent)
local f = mythicDungeonCharts.ReadyFrame
f:SetSize (255, 80)
f:SetPoint ("center", UIParent, "center", 300, 0)
f:SetFrameStrata ("LOW")
f:EnableMouse (true)
f:SetMovable (true)
f:SetBackdrop ({edgeFile = [[Interface\Buttons\WHITE8X8]], edgeSize = 1, bgFile = [[Interface\Tooltips\UI-Tooltip-Background]], tileSize = 64, tile = true})
f:SetBackdropColor (0, 0, 0, 0.9)
f:SetBackdropBorderColor (0, 0, 0, 1)
DetailsFramework:ApplyStandardBackdrop (f)
DetailsFramework:CreateTitleBar (f, "Details! Dungeon Chart is Ready!")
--register to libwindow
local LibWindow = LibStub ("LibWindow-1.1")
LibWindow.RegisterConfig (f, Details.mythic_plus.mythicrun_chart_frame_ready)
LibWindow.RestorePosition (f)
LibWindow.MakeDraggable (f)
LibWindow.SavePosition (f)
--show button
f.ShowButton = DetailsFramework:CreateButton (f, function() mythicDungeonCharts.ShowChart(); f:Hide() end, 80, 20, Loc ["STRING_SLASH_SHOW"])
f.ShowButton:SetTemplate (DetailsFramework:GetTemplate ("button", "DETAILS_PLUGIN_BUTTON_TEMPLATE"))
f.ShowButton:SetPoint ("topright", f, "topright", -5, -30)
--discart button
f.DiscartButton = DetailsFramework:CreateButton (f, function() f:Hide() end, 80, 20, Loc ["STRING_DISCARD"])
f.DiscartButton:SetTemplate (DetailsFramework:GetTemplate ("button", "DETAILS_PLUGIN_BUTTON_TEMPLATE"))
f.DiscartButton:SetPoint ("right", f.ShowButton, "left", -5, 0)
--disable feature check box (dont show this again)
local on_switch_enable = function (self, _, value)
_detalhes.mythic_plus.show_damage_graphic = not value
end
local notAgainSwitch, notAgainLabel = DetailsFramework:CreateSwitch (f, on_switch_enable, not _detalhes.mythic_plus.show_damage_graphic, _, _, _, _, _, _, _, _, _, Loc ["STRING_MINITUTORIAL_BOOKMARK4"], DetailsFramework:GetTemplate ("switch", "OPTIONS_CHECKBOX_BRIGHT_TEMPLATE"), "GameFontHighlightLeft")
notAgainSwitch:ClearAllPoints()
notAgainLabel:SetPoint ("left", notAgainSwitch, "right", 2, 0)
notAgainSwitch:SetPoint ("bottomleft", f, "bottomleft", 5, 5)
notAgainSwitch:SetAsCheckBox()
end
mythicDungeonCharts.ReadyFrame:Show()
end
function mythicDungeonCharts.ShowChart()
if (not mythicDungeonCharts.Frame) then
mythicDungeonCharts.Frame = CreateFrame ("frame", "DetailsMythicDungeonChartFrame", UIParent)
local f = mythicDungeonCharts.Frame
f:SetSize (1200, 620)
f:SetPoint ("center", UIParent, "center", 0, 0)
f:SetFrameStrata ("LOW")
@@ -295,7 +353,7 @@ function mythicDungeonCharts.ShowChart()
--minimized frame
mythicDungeonCharts.FrameMinimized = CreateFrame ("frame", "DetailsMythicDungeonChartFrameminimized", UIParent)
local fMinimized = mythicDungeonCharts.FrameMinimized
fMinimized:SetSize (160, 24)
fMinimized:SetPoint ("center", UIParent, "center", 0, 0)
fMinimized:SetFrameStrata ("LOW")
@@ -391,49 +449,7 @@ function mythicDungeonCharts.ShowChart()
f.BossWidgetsFrame.GraphPinGlow:SetSize (14, 14)
f.BossWidgetsFrame.GraphPinGlow:SetBlendMode ("ADD")
f.BossWidgetsFrame.GraphPinGlow:SetPoint ("center", f.BossWidgetsFrame.GraphPin, "center", 0, 0)
--> show animation
--> single animation group
local MainAnimationGroup = f:CreateAnimationGroup ("fAnimationGroup")
MainAnimationGroup:SetLooping ("NONE")
--> widgets:
----------------------------------------------
local NewTexture1 = f:CreateTexture ("NewTexture1Texture", "ARTWORK")
NewTexture1:SetTexture ([[Interface\Scenarios\ScenarioParts]])
NewTexture1:SetDrawLayer ("ARTWORK", 0)
NewTexture1:SetPoint ("center", f, "center", 0, 0)
NewTexture1:SetSize (1200, 600)
NewTexture1:SetTexCoord (0.0010000000149012, 0.63868587493897, 0.0010000000149012, 0.19874391555786)
--> animations for NewTexture1
NewTexture1.alpha = MainAnimationGroup:CreateAnimation ("ALPHA")
NewTexture1.alpha:SetTarget (f)
NewTexture1.alpha:SetOrder (1)
NewTexture1.alpha:SetDuration (0.090000038147)
NewTexture1.alpha:SetStartDelay (0)
NewTexture1.alpha:SetEndDelay (0)
NewTexture1.alpha:SetFromAlpha (0)
NewTexture1.alpha:SetToAlpha (0.5)
NewTexture1.alpha = MainAnimationGroup:CreateAnimation ("ALPHA")
NewTexture1.alpha:SetTarget (f)
NewTexture1.alpha:SetOrder (2)
NewTexture1.alpha:SetDuration (0.090000038147)
NewTexture1.alpha:SetStartDelay (0)
NewTexture1.alpha:SetEndDelay (0)
NewTexture1.alpha:SetFromAlpha (0.5)
NewTexture1.alpha:SetToAlpha (1)
MainAnimationGroup:SetScript ("OnPlay", function()
NewTexture1:Hide()
end)
MainAnimationGroup:SetScript ("OnFinished", function()
NewTexture1:Hide()
end)
f:Hide()
function f.ShowChartFrame()
@@ -443,7 +459,6 @@ function mythicDungeonCharts.ShowChart()
f:Show()
else
f:Show()
MainAnimationGroup:Play()
end
end
+1
View File
@@ -1341,6 +1341,7 @@ local default_global_data = {
last_mythicrun_chart = {},
mythicrun_chart_frame = {},
mythicrun_chart_frame_minimized = {},
mythicrun_chart_frame_ready = {},
},
--> plugin window positions
+1 -1
View File
@@ -9,7 +9,7 @@ do
-- UldirRaid_Icon256x128.tga
local INSTANCE_EJID = 1031
local INSTANCE_MAPID = 1148
local INSTANCE_MAPID = 1861
local HDIMAGESPATH = "Details\\images\\raid"
local HDFILEPREFIX = "UldirRaid"
local LOADINGSCREEN_FILE, LOADINGSCREEN_COORDS = "Loadingscreen_NazmirRaid", {0, 1, 285/1024, 875/1024}
+5 -5
View File
@@ -2171,7 +2171,7 @@ local icon_frame_on_enter = function (self)
local talents = _detalhes.cached_talents [serial]
local ilvl = _detalhes.ilevel:GetIlvl (serial)
local icon_size = 16
local icon_size = 20
local instance = _detalhes:GetInstance (self.row.instance_id)
@@ -2203,13 +2203,13 @@ local icon_frame_on_enter = function (self)
if (talents) then
for i = 1, #talents do
local talentID, name, texture, selected, available = GetTalentInfoByID (talents [i])
talent_string = talent_string .. " |T" .. texture .. ":" .. 15 .. ":" .. 15 ..":0:0:64:64:4:60:4:60|t"
talent_string = talent_string .. " |T" .. texture .. ":" .. 24 .. ":" .. 24 ..":0:0:64:64:4:60:4:60|t"
end
end
local got_info
if (ilvl) then
GameCooltip:AddLine (STAT_AVERAGE_ITEM_LEVEL .. ":", ilvl and floor (ilvl.ilvl) or "??") --> Loc from GlobalStrings.lua
GameCooltip:AddLine (STAT_AVERAGE_ITEM_LEVEL .. ":" , ilvl and "|T:" .. 24 .. ":" .. 24 ..":0:0:64:64:4:60:4:60|t" .. floor (ilvl.ilvl) or "|T:" .. 24 .. ":" .. 24 ..":0:0:64:64:4:60:4:60|t ??") --> Loc from GlobalStrings.lua
_detalhes:AddTooltipBackgroundStatusbar()
got_info = true
end
@@ -2227,11 +2227,11 @@ local icon_frame_on_enter = function (self)
GameCooltip:SetOption ("MinButtonHeight", 15)
GameCooltip:SetOption ("IgnoreButtonAutoHeight", false)
local height = 52
local height = 64
if (not got_info) then
GameCooltip:AddLine (Loc ["STRING_QUERY_INSPECT"], nil, 1, "orange")
GameCooltip:AddIcon ([[Interface\TUTORIALFRAME\UI-TUTORIAL-FRAME]], 1, 1, 12, icon_size, 8/512, 70/512, 224/512, 306/512)
height = 42
height = 54
end
local combat = instance:GetShowingCombat()
@@ -26,6 +26,7 @@ local _table_insert = table.insert --> lua library local
local _unpack = unpack --> lua library local
local _bit_band = bit.band
local CONST_FONT_SIZE = 10
--> Create the plugin Object
local EncounterDetails = _detalhes:NewPluginObject ("Details_EncounterDetails", DETAILSPLUGIN_ALWAYSENABLED)
@@ -668,7 +669,9 @@ end
GameCooltip:AddLine ("Click to Report", nil, 1, "orange")
GameCooltip:AddIcon ([[Interface\TUTORIALFRAME\UI-TUTORIAL-FRAME]], 1, 1, 12, 16, 0.015625, 0.13671875, 0.4375, 0.59765625)
GameCooltip:AddStatusBar (0, 1, 1, 1, 1, 1, false, {value = 100, color = {.3, .3, .3, 1}, specialSpark = false, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
GameCooltip:AddStatusBar (0, 1, 1, 1, 1, 1, false, {value = 100, color = {.3, .3, .3, .5}, specialSpark = false, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
local statusBarBackground = {value = 100, color = {.21, .21, .21, 0.8}, texture = [[Interface\AddOns\Details\images\bar_serenity]]}
--death parser
for index, event in _ipairs (eventos) do
@@ -698,20 +701,20 @@ end
end
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s " .. spellname .. " (" .. source .. ")", "-" .. _detalhes:ToK (amount) .. overkill .. " (" .. hp .. "%)", 1, "white", "white")
GameCooltip:AddIcon (spellicon)
GameCooltip:AddIcon (spellicon, 1, 1, 16, 16, .1, .9, .1, .9)
if (event [9]) then
--> friendly fire
GameCooltip:AddStatusBar (hp, 1, "darkorange", true)
GameCooltip:AddStatusBar (hp, 1, "darkorange", true, statusBarBackground)
else
--> from a enemy
GameCooltip:AddStatusBar (hp, 1, "red", true)
GameCooltip:AddStatusBar (hp, 1, "red", true, statusBarBackground)
end
else
--> heal
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s " .. spellname .. " (" .. source .. ")", "+" .. _detalhes:ToK (amount) .. " (" .. hp .. "%)", 1, "white", "white")
GameCooltip:AddIcon (spellicon)
GameCooltip:AddStatusBar (hp, 1, "green", true)
GameCooltip:AddIcon (spellicon, 1, 1, 16, 16, .1, .9, .1, .9)
GameCooltip:AddStatusBar (hp, 1, "green", true, statusBarBackground)
end
@@ -719,8 +722,8 @@ end
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)
GameCooltip:AddIcon (spellicon, 1, 1, 16, 16, .1, .9, .1, .9)
GameCooltip:AddStatusBar (100, 1, "yellow", true, statusBarBackground)
elseif (evtype == 2 and not battleress) then
--> battle ress
@@ -730,6 +733,12 @@ end
--> last cooldown used
lastcooldown = event
elseif (evtype == 4) then
--> debuff
GameCooltip:AddLine ("" .. _cstr ("%.1f", time - hora_da_morte) .. "s [x" .. amount .. "] " .. spellname .. " (" .. source .. ")", "debuff (" .. hp .. "%)", 1, "white", "white")
GameCooltip:AddIcon (spellicon, 1, 1, 16, 16, .1, .9, .1, .9)
GameCooltip:AddStatusBar (100, 1, "purple", true, statusBarBackground)
end
end
end
@@ -781,24 +790,24 @@ local function DispellInfo (dispell, barra)
_table_sort (tabela_jogadores, _detalhes.Sort2)
--cooltip
--_GameTooltip:ClearLines()
--_GameTooltip:AddLine (barra.texto_esquerdo:GetText())
for index, tabela in _ipairs (tabela_jogadores) do
local coords = EncounterDetails.class_coords [tabela[3]]
if (not coords) then
GameCooltip:AddLine (tabela[1], tabela[2], 1, "white", "orange")
GameCooltip:AddIcon ("Interface\\GossipFrame\\DailyActiveQuestIcon")
--GameTooltip:AddDoubleLine ("|TInterface\\GossipFrame\\DailyActiveQuestIcon:14:14:0:0:16:16:0:1:0:1".."|t "..tabela[1], tabela[2], 1, 1, 1, 1, 1, 1)
else
GameCooltip:AddLine (tabela[1], tabela[2], 1, "white", "orange")
GameCooltip:AddIcon ("Interface\\AddOns\\Details\\images\\classes_small", nil, 1, 14, 14, (coords[1]), (coords[2]), (coords[3]), (coords[4]))
--GameTooltip:AddDoubleLine ("|TInterface\\AddOns\\Details\\images\\classes_small:14:14:0:0:128:128:"..(coords[1]*128)..":"..(coords[2]*128)..":"..(coords[3]*128)..":"..(coords[4]*128).."|t "..tabela[1]..": ", tabela[2], 1, 1, 1, 1, 1, 1)
end
end
local spellname = GetSpellInfo (barra.spellid)
if (spellname) then
GameTooltip:SetOwner (GameCooltipFrame1, "ANCHOR_NONE")
GameTooltip:SetSpellByID (barra.spellid)
GameTooltip:SetPoint ("topright", GameCooltipFrame1, "topleft", -2, 0)
GameTooltip:Show()
end
end
--> custom tooltip for kick details ---------------------------------------------------------------------------------------------------------
@@ -825,9 +834,14 @@ local function KickBy (magia, barra)
GameCooltip:AddLine (EncounterDetails:GetOnlyName (tabela[1]) .. ": ", tabela[2], 1, "white")
GameCooltip:AddIcon ("Interface\\AddOns\\Details\\images\\classes_small", nil, 1, 14, 14, (coords[1]), (coords[2]), (coords[3]), (coords[4]))
GameCooltip:AddStatusBar (100, 1, .3, .3, .3, .3, false, false, false)
--GameTooltip:AddDoubleLine ("|T:14:14:0:0:128:128:"...."|t "..tabela[1]..": ", tabela[2], 1, 1, 1, 1, 1, 1)
end
local spellname = GetSpellInfo (barra.spellid)
if (spellname) then
GameTooltip:SetOwner (GameCooltipFrame1, "ANCHOR_NONE")
GameTooltip:SetSpellByID (barra.spellid)
GameTooltip:SetPoint ("topright", GameCooltipFrame1, "topleft", -2, 0)
GameTooltip:Show()
end
end
@@ -840,9 +854,11 @@ local function EnemySkills (habilidade, barra)
local jogadores = habilidade [2] --> [nome od jogador] = total
local tabela_jogadores = {}
local total = 0
for nome, tabela in _pairs (jogadores) do --> tabela = [1] total tomado [2] classe
tabela_jogadores [#tabela_jogadores + 1] = {nome, tabela[1], tabela[2]}
total = total + tabela[1]
end
_table_sort (tabela_jogadores, _detalhes.Sort2)
@@ -851,17 +867,28 @@ local function EnemySkills (habilidade, barra)
local ToK = _detalhes.ToKFunctions [_detalhes.ps_abbreviation]
local topValue = tabela_jogadores [1] and tabela_jogadores [1][2]
for index, tabela in _ipairs (tabela_jogadores) do
local coords = EncounterDetails.class_coords [tabela[3]]
GameCooltip:AddLine (EncounterDetails:GetOnlyName (tabela[1]) .. ": ", ToK (_, tabela[2]), 1, "white")
GameCooltip:AddStatusBar (100, 1, .3, .3, .3, .3, false, false, false)
GameCooltip:AddLine (EncounterDetails:GetOnlyName (tabela[1]) .. ": ", ToK (_, tabela[2]) .. " (" .. format ("%.1f", tabela[2] / total * 100) .. "%)", 1, "white")
local r, g, b, a = unpack (_detalhes.tooltip.background)
GameCooltip:AddStatusBar (tabela[2] / topValue * 100, 1, r, g, b, a, false, {value = 100, color = {.21, .21, .21, 0.8}, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
if (coords) then
GameCooltip:AddIcon ("Interface\\AddOns\\Details\\images\\classes_small", nil, 1, 14, 14, (coords[1]), (coords[2]), (coords[3]), (coords[4]))
end
end
local spellname = GetSpellInfo (barra.spellid)
if (spellname) then
GameTooltip:SetOwner (GameCooltipFrame1, "ANCHOR_NONE")
GameTooltip:SetSpellByID (barra.spellid)
GameTooltip:SetPoint ("topright", GameCooltipFrame1, "topleft", -2, 0)
GameTooltip:Show()
end
end
--> custom tooltip for damage taken details ---------------------------------------------------------------------------------------------------------
@@ -903,6 +930,7 @@ local function DamageTakenDetails (jogador, barra)
local teve_melee = false
local ToK = _detalhes.ToKFunctions [_detalhes.ps_abbreviation]
local topDamage = meus_agressores[1] and meus_agressores[1][2]
for i = 1, max do
local nome_magia, _, icone_magia = _GetSpellInfo (meus_agressores[i][1])
@@ -913,7 +941,8 @@ local function DamageTakenDetails (jogador, barra)
end
GameCooltip:AddLine (nome_magia..": ", ToK (_, meus_agressores[i][2]) .. " (".._cstr("%.1f", (meus_agressores[i][2]/damage_taken) * 100).."%)", 1, "white")
GameCooltip:AddStatusBar (100, 1, .3, .3, .3, .3, false, false, false)
GameCooltip:AddStatusBar (meus_agressores[i][2] / topDamage * 100, 1, .3, .3, .3, .3, false, {value = 100, color = {.21, .21, .21, 0.8}, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
GameCooltip:AddIcon (icone_magia, nil, 1, 14, 14)
end
@@ -998,7 +1027,7 @@ function EncounterDetails:SetRowScripts (barra, index, container)
self.x = _math_floor (x)
self.y = _math_floor (y)
EncounterDetailsFrame:StartMoving()
--EncounterDetailsFrame:StartMoving()
EncounterDetailsFrame.isMoving = true
end)
@@ -1010,7 +1039,7 @@ function EncounterDetails:SetRowScripts (barra, index, container)
end
if (EncounterDetailsFrame.isMoving) then
EncounterDetailsFrame:StopMovingOrSizing()
--EncounterDetailsFrame:GetParent():StopMovingOrSizing()
EncounterDetailsFrame.isMoving = false
--instancia:SaveMainWindowPosition() --> precisa fazer algo pra salvar o trem
end
@@ -1018,6 +1047,7 @@ function EncounterDetails:SetRowScripts (barra, index, container)
local x, y = _GetCursorPosition()
x = _math_floor (x)
y = _math_floor (y)
if ((self.mouse_down+0.4 > _GetTime() and (x == self.x and y == self.y)) or (x == self.x and y == self.y)) then
_detalhes:BossInfoRowClick (self)
end
@@ -1058,34 +1088,18 @@ function EncounterDetails:SetRowScripts (barra, index, container)
DamageTakenDetails (self.jogador, barra)
elseif (self.TTT == "adds_container") then
GameCooltip:AddLine ("Hover over the arrows for:", "", 1, "white")
GameCooltip:AddLine ("Damage Taken")
GameCooltip:AddIcon ("Interface\\Buttons\\UI-MicroStream-Green", 1, 1, 14, 14, 0, 1, 1, 0)
GameCooltip:AddLine ("Damage Done to Players")
GameCooltip:AddIcon ("Interface\\Buttons\\UI-MicroStream-Red")
elseif (self.TTT == "habilidades_inimigas") then --> enemy abilytes
EnemySkills (self.jogador, self)
self:SetScript ("OnUpdate", shift_monitor)
self.spellid = self.jogador [4]
_GameTooltip:AddLine (" ")
_GameTooltip:AddLine (Loc ["STRING_HOLDSHIFT"])
EnemySkills (self.jogador, self)
elseif (self.TTT == "total_interrupt") then
KickBy (self.jogador, self)
self:SetScript ("OnUpdate", shift_monitor)
self.spellid = self.jogador [3]
_GameTooltip:AddLine (" ")
_GameTooltip:AddLine (Loc ["STRING_HOLDSHIFT"])
KickBy (self.jogador, self)
elseif (self.TTT == "dispell") then
DispellInfo (self.jogador, self)
self:SetScript ("OnUpdate", shift_monitor)
self.spellid = self.jogador [3]
_GameTooltip:AddLine (" ")
_GameTooltip:AddLine (Loc ["STRING_HOLDSHIFT"])
DispellInfo (self.jogador, self)
elseif (self.TTT == "morte") then --> deaths
KillInfo (self.jogador, self) --> aqui 2
@@ -1202,7 +1216,10 @@ function EncounterDetails:OpenAndRefresh (_, segment)
EncounterDetailsFrame.raid_name:SetText (_combat_object.is_boss.zone)
-------------- set portrait and background image --------------
local L, R, T, B, Texture = EncounterDetails:GetBossIcon (_combat_object.is_boss.mapid, _combat_object.is_boss.index)
local mapID = _combat_object.is_boss.mapid
local L, R, T, B, Texture = EncounterDetails:GetBossIcon (mapID, _combat_object.is_boss.index)
if (L) then
EncounterDetailsFrame.boss_icone:SetTexture (Texture)
EncounterDetailsFrame.boss_icone:SetTexCoord (L, R, T, B)
@@ -1211,6 +1228,7 @@ function EncounterDetails:OpenAndRefresh (_, segment)
EncounterDetailsFrame.boss_icone:SetTexCoord (0, 1, 0, 1)
end
--[=[
local file, L, R, T, B = EncounterDetails:GetRaidBackground (_combat_object.is_boss.mapid)
if (file) then
EncounterDetailsFrame.raidbackground:SetTexture (file)
@@ -1219,6 +1237,9 @@ function EncounterDetails:OpenAndRefresh (_, segment)
EncounterDetailsFrame.raidbackground:SetTexture ([[Interface\Glues\LOADINGSCREENS\LoadScreenDungeon]])
EncounterDetailsFrame.raidbackground:SetTexCoord (0, 1, 120/512, 408/512)
end
--]=]
EncounterDetailsFrame.raidbackground:SetTexture (.3, .3, .3, .5)
-------------- set totals on down frame --------------
--[[ data mine:
@@ -1247,9 +1268,8 @@ function EncounterDetails:OpenAndRefresh (_, segment)
local barra = container.barras [index]
if (not barra) then
barra = EncounterDetails:CreateRow (index, container, 1, 0, -1)
_detalhes:SetFontSize (barra.texto_esquerdo, 9)
_detalhes:SetFontSize (barra.texto_direita, 9)
_detalhes:SetFontFace (barra.texto_esquerdo, "Arial Narrow")
_detalhes:SetFontSize (barra.texto_esquerdo, CONST_FONT_SIZE)
_detalhes:SetFontSize (barra.texto_direita, CONST_FONT_SIZE)
barra.TTT = "damage_taken" -- tool tip type --> damage taken
barra.report_text = Loc ["STRING_PLUGIN_NAME"].."! "..Loc ["STRING_DAMAGE_TAKEN_REPORT"]
end
@@ -1458,9 +1478,8 @@ function EncounterDetails:OpenAndRefresh (_, segment)
barra = EncounterDetails:CreateRow (index, container, 1, 0, -1)
barra.TTT = "habilidades_inimigas" -- tool tip type --enemy abilities
barra.report_text = Loc ["STRING_PLUGIN_NAME"].."! " .. Loc ["STRING_ABILITY_DAMAGE"]
_detalhes:SetFontSize (barra.texto_esquerdo, 9)
_detalhes:SetFontSize (barra.texto_direita, 9)
_detalhes:SetFontFace (barra.texto_esquerdo, "Arial Narrow")
_detalhes:SetFontSize (barra.texto_esquerdo, CONST_FONT_SIZE)
_detalhes:SetFontSize (barra.texto_direita, CONST_FONT_SIZE)
barra.t:SetVertexColor (1, .8, .8, .8)
end
@@ -1486,15 +1505,14 @@ function EncounterDetails:OpenAndRefresh (_, segment)
end
barra.icone:SetTexture (icone_magia)
--barra.icone:SetTexCoord (_unpack (EncounterDetails.class_coords [jogador.classe]))
barra.icone:SetTexCoord (.1, .9, .1, .9)
barra:Show()
quantidade = quantidade + 1
end
end
--print (quantidade)
EncounterDetails:JB_AtualizaContainer (container, quantidade)
if (quantidade < #container.barras) then
@@ -1538,45 +1556,46 @@ function EncounterDetails:OpenAndRefresh (_, segment)
not jogador.grupo and
_bit_band (jogador.flag_original, 0x00000400) == 0
)) then --> é um inimigo ou neutro
local nome = jogador.nome
local tabela = {nome = nome, total = 0, dano_em = {}, dano_em_total = 0, damage_from = {}, damage_from_total = 0}
--> total de dano que ele causou
tabela.total = jogador.total
local nome = jogador.nome
--> em quem ele deu dano
for target_name, amount in _pairs (jogador.targets) do
local este_jogador = _combat_object (1, target_name)
if (este_jogador) then
if (este_jogador.classe ~= "PET" and este_jogador.classe ~= "UNGROUPPLAYER" and este_jogador.classe ~= "UNKNOW") then
tabela.dano_em [#tabela.dano_em +1] = {target_name, amount, este_jogador.classe}
tabela.dano_em_total = tabela.dano_em_total + amount
end
else
--print ("actor not found: " ..alvo.nome )
end
end
_table_sort (tabela.dano_em, _detalhes.Sort2)
if (not nome:find ("%*")) then
local tabela = {nome = nome, total = 0, dano_em = {}, dano_em_total = 0, damage_from = {}, damage_from_total = 0}
--> quem deu dano nele
for agressor, _ in _pairs (jogador.damage_from) do
--local este_jogador = DamageContainer._ActorTable [DamageContainer._NameIndexTable [agressor]]
local este_jogador = _combat_object (1, agressor)
if (este_jogador and este_jogador:IsPlayer()) then
for target_name, amount in _pairs (este_jogador.targets) do
if (target_name == nome) then
tabela.damage_from [#tabela.damage_from+1] = {agressor, amount, este_jogador.classe}
tabela.damage_from_total = tabela.damage_from_total + amount
--> total de dano que ele causou
tabela.total = jogador.total
--> em quem ele deu dano
for target_name, amount in _pairs (jogador.targets) do
local este_jogador = _combat_object (1, target_name)
if (este_jogador) then
if (este_jogador.classe ~= "PET" and este_jogador.classe ~= "UNGROUPPLAYER" and este_jogador.classe ~= "UNKNOW") then
tabela.dano_em [#tabela.dano_em +1] = {target_name, amount, este_jogador.classe}
tabela.dano_em_total = tabela.dano_em_total + amount
end
end
end
end
_table_sort (tabela.damage_from, sort_damage_from)
_table_sort (tabela.dano_em, _detalhes.Sort2)
--> quem deu dano nele
for agressor, _ in _pairs (jogador.damage_from) do
--local este_jogador = DamageContainer._ActorTable [DamageContainer._NameIndexTable [agressor]]
local este_jogador = _combat_object (1, agressor)
if (este_jogador and este_jogador:IsPlayer()) then
for target_name, amount in _pairs (este_jogador.targets) do
if (target_name == nome) then
tabela.damage_from [#tabela.damage_from+1] = {agressor, amount, este_jogador.classe}
tabela.damage_from_total = tabela.damage_from_total + amount
end
end
end
end
_table_sort (tabela.damage_from, sort_damage_from)
tinsert (adds, tabela)
tabela [1] = tabela.damage_from_total
tinsert (adds, tabela)
end
end
end
@@ -1591,10 +1610,6 @@ function EncounterDetails:OpenAndRefresh (_, segment)
local tabela = barra.jogador
local dano_em = tabela.dano_em
--GameTooltip:SetOwner (barra, "ANCHOR_TOPRIGHT")
--_GameTooltip:ClearLines()
--_GameTooltip:AddLine (barra.texto_esquerdo:GetText().." ".. Loc ["STRING_INFLICTED"])
GameCooltip:Preset (2)
GameCooltip:SetOwner (self)
@@ -1606,21 +1621,19 @@ function EncounterDetails:OpenAndRefresh (_, segment)
GameCooltip:SetOption ("RightBorderSize", 5)
GameCooltip:SetOption ("ButtonsYMod", 0)
GameCooltip:SetOption ("YSpacingMod", -1)
GameCooltip:SetType ("tooltip")
GameCooltip:AddLine (barra.texto_esquerdo:GetText().." ".. "Damage Done")
local topDamage = dano_em[1] and dano_em[1][2]
local dano_em_total = tabela.dano_em_total
for _, esta_tabela in _pairs (dano_em) do
local coords = EncounterDetails.class_coords [esta_tabela[3]]
GameCooltip:AddLine (esta_tabela[1]..": ", _detalhes:ToK (esta_tabela[2]).." (".. _cstr ("%.1f", esta_tabela[2]/dano_em_total*100) .."%)", 1, "white", "orange")
--GameTooltip:AddDoubleLine ("|TInterface\\AddOns\\Details\\images\\classes_small:14:14:0:0:128:128:"..(coords[1]*128)..":"..(coords[2]*128)..":"..(coords[3]*128)..":"..(coords[4]*128).."|t "..esta_tabela[1]..": ", _detalhes:comma_value(esta_tabela[2]).." (".. _cstr ("%.1f", esta_tabela[2]/dano_em_total*100) .."%)", 1, 1, 1, 1, 1, 1)
GameCooltip:AddIcon ([[Interface\AddOns\Details\images\classes_small]], 1, 1, 14, 14, (coords[1]), (coords[2]), (coords[3]), (coords[4]))
GameCooltip:AddStatusBar (0, 1, 1, 1, 1, 1, false, {value = 100, color = {.3, .3, .3, 1}, specialSpark = false, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
GameCooltip:AddStatusBar (esta_tabela[2] / topDamage * 100, 1, .3, .3, .3, .3, false, {value = 100, color = {.21, .21, .21, 0.8}, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
end
GameCooltip:AddLine (" ")
@@ -1629,10 +1642,8 @@ function EncounterDetails:OpenAndRefresh (_, segment)
end
local function _DanoRecebido (self)
self.textura:SetBlendMode ("ADD")
local barra = self:GetParent()
local barra = self
local tabela = barra.jogador
local damage_from = tabela.damage_from
@@ -1647,28 +1658,24 @@ function EncounterDetails:OpenAndRefresh (_, segment)
GameCooltip:SetOption ("RightBorderSize", 5)
GameCooltip:SetOption ("ButtonsYMod", 0)
GameCooltip:SetOption ("YSpacingMod", -1)
GameCooltip:SetType ("tooltip")
GameCooltip:AddLine (barra.texto_esquerdo:GetText().." "..Loc ["STRING_DAMAGE_TAKEN"])
--GameTooltip:SetOwner (barra, "ANCHOR_TOPRIGHT")
--GameTooltip:ClearLines()
--GameTooltip:AddLine (barra.texto_esquerdo:GetText().." "..Loc ["STRING_DAMAGE_TAKEN"])
local damage_from_total = tabela.damage_from_total
local topDamage = damage_from[1] and damage_from[1][2]
for _, esta_tabela in _pairs (damage_from) do
local coords = EncounterDetails.class_coords [esta_tabela[3]]
if (coords) then
--GameTooltip:AddDoubleLine ("|TInterface\\AddOns\\Details\\images\\classes_small:14:14:0:0:128:128:"..(coords[1]*128)..":"..(coords[2]*128)..":"..(coords[3]*128)..":"..(coords[4]*128).."|t "..esta_tabela[1]..": ", _detalhes:comma_value(esta_tabela[2]).." (".. _cstr ("%.1f", esta_tabela[2]/damage_from_total*100) .."%)", 1, 1, 1, 1, 1, 1)
GameCooltip:AddLine (esta_tabela[1]..": ", _detalhes:ToK (esta_tabela[2]).." (".. _cstr ("%.1f", esta_tabela[2]/damage_from_total*100) .."%)", 1, "white", "orange")
GameCooltip:AddIcon ([[Interface\AddOns\Details\images\classes_small]], 1, 1, 14, 14, (coords[1]), (coords[2]), (coords[3]), (coords[4]))
GameCooltip:AddStatusBar (0, 1, 1, 1, 1, 1, false, {value = 100, color = {.3, .3, .3, 1}, specialSpark = false, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
GameCooltip:AddStatusBar (esta_tabela[2] / topDamage * 100, 1, .3, .3, .3, .3, false, {value = 100, color = {.21, .21, .21, 0.8}, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
else
--GameTooltip:AddDoubleLine (esta_tabela[1], _detalhes:comma_value(esta_tabela[2]).." (".. _cstr ("%.1f", esta_tabela[2]/damage_from_total*100) .."%)", 1, 1, 1, 1, 1, 1)
GameCooltip:AddLine (esta_tabela[1]..": ", _detalhes:ToK (esta_tabela[2]).." (".. _cstr ("%.1f", esta_tabela[2]/damage_from_total*100) .."%)")
GameCooltip:AddStatusBar (0, 1, 1, 1, 1, 1, false, {value = 100, color = {.3, .3, .3, 1}, specialSpark = false, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
GameCooltip:AddStatusBar (esta_tabela[2] / topDamage * 100, 1, .3, .3, .3, .3, false, {value = 100, color = {.21, .21, .21, 0.8}, texture = [[Interface\AddOns\Details\images\bar_serenity]]})
end
end
@@ -1680,7 +1687,7 @@ function EncounterDetails:OpenAndRefresh (_, segment)
local function _OnHide (self)
--GameTooltip:Hide()
GameCooltip:Hide()
self.textura:SetBlendMode ("BLEND")
--self.textura:SetBlendMode ("BLEND")
end
local y = 10
@@ -1689,94 +1696,69 @@ function EncounterDetails:OpenAndRefresh (_, segment)
local index = 1
quantidade = 0
table.sort (adds, sort_by_name)
--table.sort (adds, sort_by_name)
table.sort (adds, _detalhes.Sort1)
for index, esta_tabela in _ipairs (adds) do
local addName = esta_tabela.nome
local barra = container.barras [index]
if (not barra) then
barra = EncounterDetails:CreateRow (index, container, -0)
--barra:SetBackdrop (backdrop_bar_onleave)
--barra:SetBackdropColor (.0, .0, .0, 0.3)
barra:SetWidth (155)
barra._no_report = true
barra.TTT = "adds_container"
--> criar 2 botão: um para o dano que add deu e outro para o dano que o add tomou
local add_damage_taken = _CreateFrame ("Button", nil, barra)
add_damage_taken.report_text = "Details! Damage Taken of "
add_damage_taken.barra = barra
add_damage_taken:SetWidth (16)
add_damage_taken:SetHeight (16)
add_damage_taken:EnableMouse (true)
add_damage_taken:SetResizable (false)
add_damage_taken:SetPoint ("left", barra, "left", 0, 0)
add_damage_taken:SetBackdrop ({bgFile = [[Interface\AddOns\Details\images\background]], tile = true, tileSize = 16})
add_damage_taken:SetBackdropColor (.0, .5, .0, 0.5)
add_damage_taken:SetScript ("OnEnter", _DanoRecebido)
add_damage_taken:SetScript ("OnLeave", _OnHide)
add_damage_taken:SetScript ("OnClick", EncounterDetails.BossInfoRowClick)
add_damage_taken.textura = add_damage_taken:CreateTexture (nil, "overlay")
add_damage_taken.textura:SetTexture ("Interface\\Buttons\\UI-MicroStream-Green")
add_damage_taken.textura:SetWidth (16)
add_damage_taken.textura:SetHeight (16)
add_damage_taken.textura:SetTexCoord (0, 1, 1, 0)
add_damage_taken.textura:SetPoint ("center", add_damage_taken, "center")
local add_damage_done = _CreateFrame ("Button", nil, barra)
add_damage_done.report_text = "Details! Damage Done of "
add_damage_done.barra = barra
add_damage_done:SetWidth (16)
add_damage_done:SetHeight (16)
add_damage_done:EnableMouse (true)
add_damage_done:SetResizable (false)
add_damage_done:SetPoint ("left", add_damage_taken, "right", 0, 0)
add_damage_done:SetBackdrop ({bgFile = [[Interface\AddOns\Details\images\background]], tile = true, tileSize = 16})
add_damage_done:SetBackdropColor (.5, .0, .0, 0.5)
add_damage_done.textura = add_damage_done:CreateTexture (nil, "overlay")
add_damage_done.textura:SetTexture ("Interface\\Buttons\\UI-MicroStream-Red")
add_damage_done.textura:SetWidth (16)
add_damage_done.textura:SetHeight (16)
add_damage_done.textura:SetPoint ("topleft", add_damage_done, "topleft")
add_damage_done:SetScript ("OnEnter", _DanoFeito)
add_damage_done:SetScript ("OnLeave", _OnHide)
add_damage_done:SetScript ("OnClick", EncounterDetails.BossInfoRowClick)
barra.texto_esquerdo:SetPoint ("left", add_damage_done, "right")
barra.textura:SetStatusBarTexture (nil)
_detalhes:SetFontSize (barra.texto_esquerdo, 9)
_detalhes:SetFontSize (barra.texto_direita, 9)
add_damage_taken.TTT = "add"
add_damage_done.TTT = "add"
--barra.TTT = "habilidades_inimigas" -- tool tip type
end
local addName = esta_tabela.nome
local barra = container.barras [index]
if (not barra) then
barra = EncounterDetails:CreateRow (index, container, -0)
barra:SetWidth (155)
barra:SetScript ("OnEnter", _DanoRecebido)
barra:SetScript ("OnLeave", _OnHide)
barra:HookScript ("OnMouseDown", EncounterDetails.BossInfoRowClick)
local add_damage_done = _CreateFrame ("Button", nil, barra)
barra.report_text = "Details! Tamage Taken of "
add_damage_done.report_text = "Details! Damage Done of "
add_damage_done.barra = barra
add_damage_done:SetWidth (16)
add_damage_done:SetHeight (16)
add_damage_done:EnableMouse (true)
add_damage_done:SetResizable (false)
add_damage_done:SetPoint ("left", barra, "left", 0, 0)
add_damage_done:SetBackdrop ({bgFile = [[Interface\AddOns\Details\images\background]], tile = true, tileSize = 16})
add_damage_done:SetBackdropColor (.5, .0, .0, 0.5)
add_damage_done.textura = add_damage_done:CreateTexture (nil, "overlay")
add_damage_done.textura:SetTexture ("Interface\\Buttons\\UI-MicroStream-Red")
add_damage_done.textura:SetWidth (16)
add_damage_done.textura:SetHeight (16)
add_damage_done.textura:SetPoint ("topleft", add_damage_done, "topleft")
add_damage_done:SetScript ("OnEnter", _DanoFeito)
add_damage_done:SetScript ("OnLeave", _OnHide)
add_damage_done:SetScript ("OnClick", EncounterDetails.BossInfoRowClick)
barra.texto_esquerdo:SetPoint ("left", add_damage_done, "right", 2, 0)
barra.textura:SetStatusBarTexture (nil)
_detalhes:SetFontSize (barra.texto_esquerdo, CONST_FONT_SIZE)
_detalhes:SetFontSize (barra.texto_direita, CONST_FONT_SIZE)
barra.TTT = "add"
add_damage_done.TTT = "add"
end
barra.texto_esquerdo:SetText (addName)
barra.texto_direita:SetText (_detalhes:ToK (esta_tabela.total))
barra.texto_esquerdo:SetSize (barra:GetWidth() - barra.texto_direita:GetStringWidth() - 34, 15)
barra.jogador = esta_tabela --> barra.jogador agora tem a tabela com --> [1] total dano causado [2] jogadores que foram alvos [3] jogadores que castaram essa magia [4] ID da magia
--barra.textura:SetStatusBarColor (_unpack (_detalhes.class_colors [jogador.classe]))
barra.textura:SetStatusBarColor (1, 1, 1, 1) --> a cor pode ser a spell school da magia
barra.textura:SetValue (100)
barra:Show()
quantidade = quantidade + 1
index = index +1
barra.texto_esquerdo:SetText (addName)
barra.texto_direita:SetText (_detalhes:ToK (esta_tabela.damage_from_total))
barra.texto_esquerdo:SetSize (barra:GetWidth() - barra.texto_direita:GetStringWidth() - 34, 15)
barra.jogador = esta_tabela --> barra.jogador agora tem a tabela com --> [1] total dano causado [2] jogadores que foram alvos [3] jogadores que castaram essa magia [4] ID da magia
--barra.textura:SetStatusBarColor (_unpack (_detalhes.class_colors [jogador.classe]))
barra.textura:SetStatusBarColor (1, 1, 1, 1) --> a cor pode ser a spell school da magia
barra.textura:SetValue (100)
barra:Show()
quantidade = quantidade + 1
index = index +1
end
EncounterDetails:JB_AtualizaContainer (container, quantidade, 4)
@@ -1844,6 +1826,8 @@ function EncounterDetails:OpenAndRefresh (_, segment)
local barra = container.barras [index]
if (not barra) then
barra = EncounterDetails:CreateRow (index, container, 3, 0, -6)
_detalhes:SetFontSize (barra.texto_esquerdo, CONST_FONT_SIZE)
_detalhes:SetFontSize (barra.texto_direita, CONST_FONT_SIZE)
barra.TTT = "total_interrupt" -- tool tip type
barra.report_text = "Details! ".. Loc ["STRING_INTERRUPTS_OF"]
barra:SetWidth (155)
@@ -1956,6 +1940,8 @@ function EncounterDetails:OpenAndRefresh (_, segment)
local barra = container.barras [index]
if (not barra) then
barra = EncounterDetails:CreateRow (index, container, 3, 3, -6)
_detalhes:SetFontSize (barra.texto_esquerdo, CONST_FONT_SIZE)
_detalhes:SetFontSize (barra.texto_direita, CONST_FONT_SIZE)
barra.TTT = "dispell" -- tool tip type
barra.report_text = "Details! ".. Loc ["STRING_DISPELLS_OF"]
barra:SetWidth (160)
@@ -2016,9 +2002,8 @@ function EncounterDetails:OpenAndRefresh (_, segment)
barra = EncounterDetails:CreateRow (index, container, 3, 0, 1)
barra.TTT = "morte" -- tool tip type
barra.report_text = "Details! " .. Loc ["STRING_DEAD_LOG"]
_detalhes:SetFontSize (barra.texto_esquerdo, 9)
_detalhes:SetFontSize (barra.texto_direita, 9)
_detalhes:SetFontFace (barra.texto_esquerdo, "Arial Narrow")
_detalhes:SetFontSize (barra.texto_esquerdo, CONST_FONT_SIZE)
_detalhes:SetFontSize (barra.texto_direita, CONST_FONT_SIZE)
barra:SetWidth (169)
end
+21 -19
View File
@@ -203,7 +203,7 @@ _detalhes.EncounterDetailsTempWindow = function (EncounterDetails)
end
function EncounterDetails:CreateRow (index, container, x_mod, y_mod, width_mod)
local barra = CreateFrame ("Button", "Details_"..container:GetName().."_barra_"..index, container)
x_mod = x_mod or 0
@@ -211,7 +211,7 @@ _detalhes.EncounterDetailsTempWindow = function (EncounterDetails)
barra:SetWidth (200+width_mod) --> tamanho da barra de acordo com o tamanho da janela
barra:SetHeight (16) --> altura determinada pela instância
local y = (index-1)*17
y_mod = y_mod or 0
y = y + y_mod
@@ -221,28 +221,28 @@ _detalhes.EncounterDetailsTempWindow = function (EncounterDetails)
barra:SetPoint ("RIGHT", container, "RIGHT", width_mod, 0)
barra:SetPoint ("TOP", container, "TOP", 0, y)
barra:SetFrameLevel (container:GetFrameLevel() + 1)
barra:EnableMouse (true)
barra:RegisterForClicks ("LeftButtonDown","RightButtonUp")
EncounterDetails:CreateRowTexture (barra)
barra:SetBackdrop (BackdropDefault)
EncounterDetails.SetBarBackdrop_OnLeave (barra)
--> icone
barra.icone = barra.textura:CreateTexture (nil, "OVERLAY")
barra.icone:SetWidth (14)
barra.icone:SetHeight (14)
barra.icone:SetWidth (16)
barra.icone:SetHeight (16)
barra.icone:SetPoint ("RIGHT", barra.textura, "LEFT", 0+20, 0)
barra:SetAlpha(0.9)
barra:SetAlpha (0.9)
barra.icone:SetAlpha (0.8)
EncounterDetails:SetRowScripts (barra, index, container)
container.barras [index] = barra
return barra
end
@@ -2073,7 +2073,8 @@ _detalhes.EncounterDetailsTempWindow = function (EncounterDetails)
local spellname, _, spellicon = _GetSpellInfo (spell)
tinsert (t, {label = spellname, value = {timer_table [2], spellname, spellIcon or spellicon, timer_table.id, timer_table [7]}, icon = spellIcon or spellicon, onclick = on_select_dbm_bar})
else
local title, description, depth, abilityIcon, displayInfo, siblingID, nextSectionID, filteredByDifficulty, link, startsOpen, flag1, flag2, flag3, flag4 = EJ_GetSectionInfo (spell)
--local title, description, depth, abilityIcon, displayInfo, siblingID, nextSectionID, filteredByDifficulty, link, startsOpen, flag1, flag2, flag3, flag4 = EJ_GetSectionInfo (spell)
local title, description, depth, abilityIcon, displayInfo, siblingID, nextSectionID, filteredByDifficulty, link, startsOpen, flag1, flag2, flag3, flag4 = C_EncounterJournal.GetSectionInfo (spell)
tinsert (t, {label = title, value = {timer_table [2], title, spellIcon or abilityIcon, timer_table.id, timer_table [7]}, icon = spellIcon or abilityIcon, onclick = on_select_dbm_bar})
end
already_added [spell] = true
@@ -2100,7 +2101,8 @@ _detalhes.EncounterDetailsTempWindow = function (EncounterDetails)
local spellname = timer_table [2]:gsub (" %(.%)", "")
tinsert (t, {label = spellname, value = {timer_table [2], spellname, timer_table [5], timer_table.id}, icon = timer_table [5], onclick = on_select_bw_bar})
elseif (int_spell < 0) then
local title, description, depth, abilityIcon, displayInfo, siblingID, nextSectionID, filteredByDifficulty, link, startsOpen, flag1, flag2, flag3, flag4 = EJ_GetSectionInfo (abs (int_spell))
--local title, description, depth, abilityIcon, displayInfo, siblingID, nextSectionID, filteredByDifficulty, link, startsOpen, flag1, flag2, flag3, flag4 = EJ_GetSectionInfo (abs (int_spell))
local title, description, depth, abilityIcon, displayInfo, siblingID, nextSectionID, filteredByDifficulty, link, startsOpen, flag1, flag2, flag3, flag4 = C_EncounterJournal.GetSectionInfo (abs (int_spell))
tinsert (t, {label = title, value = {timer_table [2], title, timer_table [5] or abilityIcon, timer_table.id}, icon = timer_table [5] or abilityIcon, onclick = on_select_bw_bar})
else
local spellname, _, spellicon = _GetSpellInfo (int_spell)
@@ -2642,7 +2644,7 @@ end
frame.Widgets [#frame.Widgets+1] = dano_recebido_bg
DetailsFrameWork:NewLabel (dano_recebido_bg, dano_recebido_bg, nil, "damagetaken_title", "Damage Taken per Player", "GameFontHighlight") --localize-me
dano_recebido_bg.damagetaken_title:SetPoint ("BOTTOMLEFT", container_damagetaken_window, "TOPLEFT", 5, 0)
dano_recebido_bg.damagetaken_title:SetPoint ("BOTTOMLEFT", container_damagetaken_window, "TOPLEFT", 5, 1)
container_damagetaken_frame:SetBackdrop (backdrop)
container_damagetaken_frame:SetBackdropBorderColor (0,0,0,0)
@@ -2696,7 +2698,7 @@ end
frame.Widgets [#frame.Widgets+1] = container_habilidades_frame
DetailsFrameWork:NewLabel (habilidades_inimigas_bg, habilidades_inimigas_bg, nil, "habilidades_title", "Damage Taken by Spell", "GameFontHighlight") --localize-me
habilidades_inimigas_bg.habilidades_title:SetPoint ("BOTTOMLEFT", container_habilidades_window, "TOPLEFT", 5, 0)
habilidades_inimigas_bg.habilidades_title:SetPoint ("BOTTOMLEFT", container_habilidades_window, "TOPLEFT", 5, 1)
container_habilidades_frame:SetBackdrop (backdrop)
container_habilidades_frame:SetBackdropBorderColor (0,0,0,0)
@@ -2740,7 +2742,7 @@ end
frame.Widgets [#frame.Widgets+1] = container_adds_window
container_adds_frame.barras = {}
local adds_total_string = DetailsFrameWork:CreateLabel (container_adds_window, "damage done")
local adds_total_string = DetailsFrameWork:CreateLabel (container_adds_window, "damage taken")
adds_total_string.textcolor = "gray"
adds_total_string.textsize = 9
adds_total_string:SetPoint ("bottomright", container_adds_window, "topright", 0, 3)
@@ -2757,8 +2759,8 @@ end
container_adds_window:SetScrollChild (container_adds_frame)
container_adds_window:SetPoint ("TOPLEFT", container_damagetaken_window, "topright", CONST_BOX_HORIZONTAL_SPACING, 0)
DetailsFrameWork:NewLabel (container_adds_window, container_adds_window, nil, "titulo", Loc ["STRING_ADDS"], "GameFontHighlight")
container_adds_window.titulo:SetPoint ("bottomleft", container_adds_window, "topleft", 0, 0)
DetailsFrameWork:NewLabel (container_adds_window, container_adds_window, nil, "titulo", "Enemy Damage Taken", "GameFontHighlight")
container_adds_window.titulo:SetPoint ("bottomleft", container_adds_window, "topleft", 0, 1)
DetailsFrameWork:NewScrollBar (container_adds_window, container_adds_frame, 4, -16)
container_adds_window.slider:Altura (BOX_HEIGHT - 31)
@@ -2803,7 +2805,7 @@ end
container_interrupt_window:SetPoint ("TOPLEFT", container_adds_window, "TOPRIGHT", CONST_BOX_HORIZONTAL_SPACING, 0)
DetailsFrameWork:NewLabel (container_interrupt_window, container_interrupt_window, nil, "titulo", Loc ["STRING_INTERRUPTS"], "GameFontHighlight")
container_interrupt_window.titulo:SetPoint ("bottomleft", container_interrupt_window, "topleft", 0, 0)
container_interrupt_window.titulo:SetPoint ("bottomleft", container_interrupt_window, "topleft", 0, 1)
DetailsFrameWork:NewScrollBar (container_interrupt_window, container_interrupt_frame, 4, -16)
container_interrupt_window.slider:Altura (BOX_HEIGHT-31)
@@ -2849,7 +2851,7 @@ end
container_dispell_window:SetPoint ("TOPLEFT", container_adds_window, "BOTTOMLEFT", 0, CONST_BOX_VERTICAL_SPACING)
DetailsFrameWork:NewLabel (container_dispell_window, container_dispell_window, nil, "titulo", Loc ["STRING_DISPELLS"], "GameFontHighlight")
container_dispell_window.titulo:SetPoint ("bottomleft", container_dispell_window, "topleft", 0, 0)
container_dispell_window.titulo:SetPoint ("bottomleft", container_dispell_window, "topleft", 0, 1)
DetailsFrameWork:NewScrollBar (container_dispell_window, container_dispell_frame, 4, -16)
container_dispell_window.slider:Altura (BOX_HEIGHT-31)
@@ -2899,7 +2901,7 @@ end
container_dead_window:SetPoint ("TOPLEFT", container_dispell_window, "TOPRIGHT", CONST_BOX_HORIZONTAL_SPACING, 0)
DetailsFrameWork:NewLabel (container_dead_window, container_dead_window, nil, "titulo", Loc ["STRING_DEATH_LOG"], "GameFontHighlight")
container_dead_window.titulo:SetPoint ("bottomleft", container_dead_window, "topleft", 0, 0)
container_dead_window.titulo:SetPoint ("bottomleft", container_dead_window, "topleft", 0, 1)
DetailsFrameWork:NewScrollBar (container_dead_window, container_dead_frame, 4, -16)
container_dead_window.slider:Altura (BOX_HEIGHT-31)
@@ -576,7 +576,7 @@ end
local talentsTable = _detalhes:GetTalents (unitSerial)
--> order by class > alphabetically by the unit name
unitClassID = ((unitClassID + 128) ^ 3) + tonumber (string.byte (unitName, 1) .. "" .. string.byte (unitName, 2))
unitClassID = ((unitClassID + 128) ^ 4) + tonumber (string.byte (unitName, 1) .. "" .. string.byte (unitName, 2))
tinsert (PlayerData, {unitName, unitClassID,
Name = unitName,
@@ -607,7 +607,7 @@ end
local itemLevelTable = _detalhes.ilevel:GetIlvl (unitSerial)
local talentsTable = _detalhes:GetTalents (unitSerial)
unitClassID = ((unitClassID + 128) ^ 3) + tonumber (string.byte (unitName, 1) .. "" .. string.byte (unitName, 2))
unitClassID = ((unitClassID + 128) ^ 4) + tonumber (string.byte (unitName, 1) .. "" .. string.byte (unitName, 2))
tinsert (PlayerData, {unitName, unitClassID,
Name = unitName,
+1 -1
View File
@@ -1848,7 +1848,7 @@ function _G._detalhes:Start()
C_Timer.After (2, function()
_detalhes:RefreshPlaterIntegration()
end)
--> override the overall data flag on this release only (remove on the release)
Details.overall_flag = 0x10