- Improvements on our support for Arena battles.
- Fixed some issues on the Player Detail Window.
This commit is contained in:
+77
-68
@@ -2596,6 +2596,62 @@ end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
--[[ exported]] function _detalhes:SetClassIcon (texture, instance)
|
||||
|
||||
if (self.spellicon) then
|
||||
texture:SetTexture (self.spellicon)
|
||||
texture:SetTexCoord (0.078125, 0.921875, 0.078125, 0.921875)
|
||||
texture:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "UNKNOW") then
|
||||
texture:SetTexture ([[Interface\AddOns\Details\images\classes_plus]])
|
||||
texture:SetTexCoord (0.50390625, 0.62890625, 0, 0.125)
|
||||
|
||||
texture:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "UNGROUPPLAYER") then
|
||||
if (self.enemy) then
|
||||
if (_detalhes.faction_against == "Horde") then
|
||||
texture:SetTexture ("Interface\\ICONS\\Achievement_Character_Orc_Male")
|
||||
texture:SetTexCoord (0, 1, 0, 1)
|
||||
else
|
||||
texture:SetTexture ("Interface\\ICONS\\Achievement_Character_Human_Male")
|
||||
texture:SetTexCoord (0, 1, 0, 1)
|
||||
end
|
||||
else
|
||||
if (_detalhes.faction_against == "Horde") then
|
||||
texture:SetTexture ("Interface\\ICONS\\Achievement_Character_Human_Male")
|
||||
texture:SetTexCoord (0, 1, 0, 1)
|
||||
else
|
||||
texture:SetTexture ("Interface\\ICONS\\Achievement_Character_Orc_Male")
|
||||
texture:SetTexCoord (0, 1, 0, 1)
|
||||
end
|
||||
end
|
||||
texture:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "PET") then
|
||||
texture:SetTexture (instance and instance.row_info.icon_file or [[Interface\AddOns\Details\images\classes_small]])
|
||||
texture:SetTexCoord (0.25, 0.49609375, 0.75, 1)
|
||||
texture:SetVertexColor (actor_class_color_r, actor_class_color_g, actor_class_color_b)
|
||||
else
|
||||
if (instance and instance.row_info.use_spec_icons) then
|
||||
if (self.spec) then
|
||||
texture:SetTexture (instance.row_info.spec_file)
|
||||
texture:SetTexCoord (_unpack (_detalhes.class_specs_coords [self.spec]))
|
||||
texture:SetVertexColor (1, 1, 1)
|
||||
else
|
||||
texture:SetTexture ([[Interface\AddOns\Details\images\classes_small]])
|
||||
texture:SetTexCoord (_unpack (CLASS_ICON_TCOORDS [self.classe]))
|
||||
texture:SetVertexColor (1, 1, 1)
|
||||
end
|
||||
else
|
||||
texture:SetTexture (instance and instance.row_info.icon_file or [[Interface\AddOns\Details\images\classes_small]])
|
||||
texture:SetTexCoord (_unpack (CLASS_ICON_TCOORDS [self.classe]))
|
||||
texture:SetVertexColor (1, 1, 1)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
--[[ exported]] function _detalhes:RefreshBarra (esta_barra, instancia, from_resize)
|
||||
|
||||
@@ -2611,59 +2667,7 @@ end
|
||||
end
|
||||
|
||||
--icon
|
||||
if (self.spellicon) then
|
||||
esta_barra.icone_classe:SetTexture (self.spellicon)
|
||||
esta_barra.icone_classe:SetTexCoord (0.078125, 0.921875, 0.078125, 0.921875)
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "UNKNOW") then
|
||||
esta_barra.icone_classe:SetTexture ([[Interface\AddOns\Details\images\classes_plus]])
|
||||
esta_barra.icone_classe:SetTexCoord (0.50390625, 0.62890625, 0, 0.125)
|
||||
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "UNGROUPPLAYER") then
|
||||
if (self.enemy) then
|
||||
if (_detalhes.faction_against == "Horde") then
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Orc_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Human_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
end
|
||||
else
|
||||
if (_detalhes.faction_against == "Horde") then
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Human_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Orc_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
end
|
||||
end
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "PET") then
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.icon_file)
|
||||
esta_barra.icone_classe:SetTexCoord (0.25, 0.49609375, 0.75, 1)
|
||||
esta_barra.icone_classe:SetVertexColor (actor_class_color_r, actor_class_color_g, actor_class_color_b)
|
||||
|
||||
else
|
||||
if (instancia.row_info.use_spec_icons) then
|
||||
if (self.spec) then
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.spec_file)
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (_detalhes.class_specs_coords [self.spec]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ([[Interface\AddOns\Details\images\classes_small]])
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (CLASS_ICON_TCOORDS [self.classe]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
end
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.icon_file)
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (CLASS_ICON_TCOORDS [self.classe]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
end
|
||||
end
|
||||
self:SetClassIcon (esta_barra.icone_classe, instancia)
|
||||
|
||||
--texture and text
|
||||
local bar_number = ""
|
||||
@@ -3922,18 +3926,24 @@ function atributo_damage:MontaInfoDamageDone()
|
||||
barra.textura:SetValue (tabela[2]/max_inimigos*100)
|
||||
end
|
||||
|
||||
barra.textura:SetStatusBarColor (1, 0.8, 0.8)
|
||||
|
||||
barra.icone:SetTexture ([[Interface\AddOns\Details\images\classes_small_alpha]]) --CLASSE
|
||||
|
||||
local texCoords = _detalhes.class_coords ["ENEMY"]
|
||||
barra.icone:SetTexCoord (_unpack (texCoords))
|
||||
|
||||
barra.texto_esquerdo:SetText (index..instancia.divisores.colocacao..tabela[1]) --seta o texto da esqueda
|
||||
if (info.sub_atributo == 2) then
|
||||
barra.texto_direita:SetText (_detalhes:comma_value ( _math_floor (tabela[2]/meu_tempo)) .." ".. instancia.divisores.abre .._cstr("%.1f", tabela[3]) .. instancia.divisores.fecha) --seta o texto da direita
|
||||
local target_actor = instancia.showing (1, tabela[1])
|
||||
if (target_actor) then
|
||||
target_actor:SetClassIcon (barra.icone, instancia)
|
||||
else
|
||||
barra.texto_direita:SetText (_detalhes:comma_value (tabela[2]) .." ".. instancia.divisores.abre .._cstr("%.1f", tabela[3]) .. instancia.divisores.fecha) --seta o texto da direita
|
||||
barra.icone:SetTexture ([[Interface\AddOns\Details\images\classes_small_alpha]]) --CLASSE
|
||||
local texCoords = _detalhes.class_coords ["ENEMY"]
|
||||
barra.icone:SetTexCoord (_unpack (texCoords))
|
||||
end
|
||||
|
||||
barra.textura:SetStatusBarColor (1, 0.8, 0.8)
|
||||
barra.textura:SetStatusBarColor (1, 1, 1, 1)
|
||||
|
||||
barra.texto_esquerdo:SetText (index .. ". " .. _detalhes:GetOnlyName (tabela[1]))
|
||||
|
||||
if (info.sub_atributo == 2) then
|
||||
barra.texto_direita:SetText (_detalhes:comma_value ( _math_floor (tabela[2]/meu_tempo)) .. " (" .. _cstr ("%.1f", tabela[3]) .. "%)")
|
||||
else
|
||||
barra.texto_direita:SetText (SelectedToKFunction (_, tabela[2]) .." (" .. _cstr ("%.1f", tabela[3]) .. "%)")
|
||||
end
|
||||
|
||||
if (barra.mouse_over) then --> atualizar o tooltip
|
||||
@@ -4424,7 +4434,7 @@ function atributo_damage:MontaTooltipDamageTaken (esta_barra, index)
|
||||
end
|
||||
|
||||
_table_sort (habilidades, _detalhes.Sort2)
|
||||
|
||||
|
||||
GameTooltip:AddLine (index..". "..esta_barra.nome_inimigo)
|
||||
GameTooltip:AddLine (Loc ["STRING_DAMAGE_TAKEN_FROM2"]..":")
|
||||
GameTooltip:AddLine (" ")
|
||||
@@ -4433,7 +4443,6 @@ function atributo_damage:MontaTooltipDamageTaken (esta_barra, index)
|
||||
local nome, _, icone = _GetSpellInfo (tabela[1])
|
||||
if (index < 8) then
|
||||
GameTooltip:AddDoubleLine (index..". |T"..icone..":0|t "..nome, _detalhes:comma_value (tabela[2]).." (".._cstr("%.1f", tabela[2]/total*100).."%)", 1, 1, 1, 1, 1, 1)
|
||||
--GameTooltip:AddTexture (icone)
|
||||
else
|
||||
GameTooltip:AddDoubleLine (index..". "..nome, _detalhes:comma_value (tabela[2]).." (".._cstr("%.1f", tabela[2]/total*100).."%)", .65, .65, .65, .65, .65, .65)
|
||||
end
|
||||
@@ -4535,13 +4544,13 @@ function atributo_damage:MontaTooltipAlvos (esta_barra, index, instancia)
|
||||
if (is_dps) then
|
||||
GameTooltip:AddDoubleLine (index..". |T"..tabela[3]..":0|t "..tabela[1], _detalhes:comma_value ( _math_floor (tabela[2] / meu_tempo) ).." (".._cstr("%.1f", tabela[2]/total*100).."%)", 1, 1, 1, 1, 1, 1)
|
||||
else
|
||||
GameTooltip:AddDoubleLine (index..". |T"..tabela[3]..":0|t "..tabela[1], _detalhes:comma_value (tabela[2]).." (".._cstr("%.1f", tabela[2]/total*100).."%)", 1, 1, 1, 1, 1, 1)
|
||||
GameTooltip:AddDoubleLine (index..". |T"..tabela[3]..":0|t " .. tabela[1], SelectedToKFunction (_, tabela[2]) .. " (".._cstr("%.1f", tabela[2]/total*100).."%)", 1, 1, 1, 1, 1, 1)
|
||||
end
|
||||
else
|
||||
if (is_dps) then
|
||||
GameTooltip:AddDoubleLine (index..". "..tabela[1], _detalhes:comma_value ( _math_floor (tabela[2] / meu_tempo) ).." (".._cstr("%.1f", tabela[2]/total*100).."%)", .65, .65, .65, .65, .65, .65)
|
||||
else
|
||||
GameTooltip:AddDoubleLine (index..". "..tabela[1], _detalhes:comma_value (tabela[2]).." (".._cstr("%.1f", tabela[2]/total*100).."%)", .65, .65, .65, .65, .65, .65)
|
||||
GameTooltip:AddDoubleLine (index..". "..tabela[1], SelectedToKFunction (_, tabela[2]).." (".._cstr("%.1f", tabela[2]/total*100).."%)", .65, .65, .65, .65, .65, .65)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -770,53 +770,8 @@ function atributo_energy:RefreshBarra (esta_barra, instancia, from_resize)
|
||||
esta_barra.background:SetVertexColor (actor_class_color_r, actor_class_color_g, actor_class_color_b)
|
||||
end
|
||||
|
||||
if (self.classe == "UNKNOW") then
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\LFGFRAME\\LFGROLE_BW")
|
||||
esta_barra.icone_classe:SetTexCoord (.25, .5, 0, 1)
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "UNGROUPPLAYER") then
|
||||
if (self.enemy) then
|
||||
if (_detalhes.faction_against == "Horde") then
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Orc_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Human_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
end
|
||||
else
|
||||
if (_detalhes.faction_against == "Horde") then
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Human_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Orc_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
end
|
||||
end
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "PET") then
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.icon_file)
|
||||
esta_barra.icone_classe:SetTexCoord (0.25, 0.49609375, 0.75, 1)
|
||||
esta_barra.icone_classe:SetVertexColor (actor_class_color_r, actor_class_color_g, actor_class_color_b)
|
||||
|
||||
else
|
||||
if (instancia.row_info.use_spec_icons) then
|
||||
if (self.spec) then
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.spec_file)
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (_detalhes.class_specs_coords [self.spec]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ([[Interface\AddOns\Details\images\classes_small]])
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (CLASS_ICON_TCOORDS [self.classe]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
end
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.icon_file)
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (CLASS_ICON_TCOORDS [self.classe]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
end
|
||||
end
|
||||
--icon
|
||||
self:SetClassIcon (esta_barra.icone_classe, instancia)
|
||||
|
||||
--texture and text
|
||||
|
||||
|
||||
+17
-66
@@ -863,66 +863,7 @@ function atributo_heal:RefreshBarra (esta_barra, instancia, from_resize)
|
||||
end
|
||||
|
||||
--icon
|
||||
|
||||
if (self.spellicon) then
|
||||
esta_barra.icone_classe:SetTexture (self.spellicon)
|
||||
esta_barra.icone_classe:SetTexCoord (0.078125, 0.921875, 0.078125, 0.921875)
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "UNKNOW") then
|
||||
--esta_barra.icone_classe:SetTexture ("Interface\\LFGFRAME\\LFGROLE")
|
||||
--esta_barra.icone_classe:SetTexCoord (.25, .5, 0, 1)
|
||||
|
||||
--esta_barra.icone_classe:SetTexture ([[Interface\TARGETINGFRAME\PetBadge-Undead]])
|
||||
--esta_barra.icone_classe:SetTexCoord (0.09375, 0.90625, 0.09375, 0.90625)
|
||||
|
||||
esta_barra.icone_classe:SetTexture ([[Interface\AddOns\Details\images\classes_plus]])
|
||||
esta_barra.icone_classe:SetTexCoord (0.50390625, 0.62890625, 0, 0.125)
|
||||
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "UNGROUPPLAYER") then
|
||||
if (self.enemy) then
|
||||
if (_detalhes.faction_against == "Horde") then
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Orc_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Human_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
end
|
||||
else
|
||||
if (_detalhes.faction_against == "Horde") then
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Human_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Orc_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
end
|
||||
end
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "PET") then
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.icon_file)
|
||||
esta_barra.icone_classe:SetTexCoord (0.25, 0.49609375, 0.75, 1)
|
||||
esta_barra.icone_classe:SetVertexColor (actor_class_color_r, actor_class_color_g, actor_class_color_b)
|
||||
|
||||
else
|
||||
if (instancia.row_info.use_spec_icons) then
|
||||
if (self.spec) then
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.spec_file)
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (_detalhes.class_specs_coords [self.spec]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ([[Interface\AddOns\Details\images\classes_small]])
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (CLASS_ICON_TCOORDS [self.classe]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
end
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.icon_file)
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (CLASS_ICON_TCOORDS [self.classe]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
end
|
||||
end
|
||||
self:SetClassIcon (esta_barra.icone_classe, instancia)
|
||||
|
||||
--texture and text
|
||||
|
||||
@@ -1698,15 +1639,25 @@ function atributo_heal:MontaInfoHealingDone()
|
||||
if (index == 1) then
|
||||
barra.textura:SetValue (100)
|
||||
else
|
||||
barra.textura:SetValue (tabela[2]/max_*100) --> muito mais rapido...
|
||||
barra.textura:SetValue (tabela[2]/max_*100)
|
||||
end
|
||||
|
||||
barra.texto_esquerdo:SetText (index..instancia.divisores.colocacao..tabela[1]) --seta o texto da esqueda
|
||||
local target_actor = instancia.showing (2, tabela[1])
|
||||
if (target_actor) then
|
||||
target_actor:SetClassIcon (barra.icone, instancia)
|
||||
else
|
||||
barra.icone:SetTexture ([[Interface\AddOns\Details\images\classes_small_alpha]]) --CLASSE
|
||||
local texCoords = _detalhes.class_coords ["ENEMY"]
|
||||
barra.icone:SetTexCoord (_unpack (texCoords))
|
||||
end
|
||||
|
||||
barra.texto_esquerdo:SetText (index .. ". " .. _detalhes:GetOnlyName (tabela[1]))
|
||||
barra.textura:SetStatusBarColor (1, 1, 1, 1)
|
||||
|
||||
if (info.sub_atributo == 2) then
|
||||
barra.texto_direita:SetText (_detalhes:comma_value (_math_floor (tabela[2]/meu_tempo)) .." ".. instancia.divisores.abre .. _cstr ("%.1f", tabela[3]) .. instancia.divisores.fecha)
|
||||
barra.texto_direita:SetText (_detalhes:comma_value (_math_floor (tabela[2]/meu_tempo)) .." (" .. _cstr ("%.1f", tabela[3]) .. "%)")
|
||||
else
|
||||
barra.texto_direita:SetText (_detalhes:comma_value (tabela[2]) .." ".. instancia.divisores.abre .. _cstr ("%.1f", tabela[3]) .. instancia.divisores.fecha)
|
||||
barra.texto_direita:SetText (SelectedToKFunction (_, tabela[2]) .. " (" .. _cstr ("%.1f", tabela[3]) .. "%)")
|
||||
end
|
||||
|
||||
barra.minha_tabela = self
|
||||
@@ -1793,13 +1744,13 @@ function atributo_heal:MontaTooltipAlvos (esta_barra, index, instancia)
|
||||
if (is_hps) then
|
||||
GameTooltip:AddDoubleLine (index..". |T"..icone..":0|t "..nome, _detalhes:comma_value (_math_floor (tabela[2]/meu_tempo)).." (".. _cstr ("%.1f", tabela[2]/total*100).."%)", 1, 1, 1, 1, 1, 1)
|
||||
else
|
||||
GameTooltip:AddDoubleLine (index..". |T"..icone..":0|t "..nome, _detalhes:comma_value (tabela[2]).." (".. _cstr ("%.1f", tabela[2]/total*100).."%)", 1, 1, 1, 1, 1, 1)
|
||||
GameTooltip:AddDoubleLine (index..". |T"..icone..":0|t "..nome, SelectedToKFunction (_, tabela[2]).." (".. _cstr ("%.1f", tabela[2]/total*100).."%)", 1, 1, 1, 1, 1, 1)
|
||||
end
|
||||
else
|
||||
if (is_hps) then
|
||||
GameTooltip:AddDoubleLine (index..". "..nome, _detalhes:comma_value (_math_floor (tabela[2]/meu_tempo)).." (".. _cstr ("%.1f", tabela[2]/total*100).."%)", .65, .65, .65, .65, .65, .65)
|
||||
else
|
||||
GameTooltip:AddDoubleLine (index..". "..nome, _detalhes:comma_value (tabela[2]).." (".. _cstr ("%.1f", tabela[2]/total*100).."%)", .65, .65, .65, .65, .65, .65)
|
||||
GameTooltip:AddDoubleLine (index..". "..nome, SelectedToKFunction (_, tabela[2]).." (".. _cstr ("%.1f", tabela[2]/total*100).."%)", .65, .65, .65, .65, .65, .65)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -947,53 +947,8 @@ function atributo_misc:RefreshBarra (esta_barra, instancia, from_resize)
|
||||
esta_barra.background:SetVertexColor (actor_class_color_r, actor_class_color_g, actor_class_color_b)
|
||||
end
|
||||
|
||||
if (self.classe == "UNKNOW") then
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\LFGFRAME\\LFGROLE_BW")
|
||||
esta_barra.icone_classe:SetTexCoord (.25, .5, 0, 1)
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "UNGROUPPLAYER") then
|
||||
if (self.enemy) then
|
||||
if (_detalhes.faction_against == "Horde") then
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Orc_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Human_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
end
|
||||
else
|
||||
if (_detalhes.faction_against == "Horde") then
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Human_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ("Interface\\ICONS\\Achievement_Character_Orc_Male")
|
||||
esta_barra.icone_classe:SetTexCoord (0, 1, 0, 1)
|
||||
end
|
||||
end
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
|
||||
elseif (self.classe == "PET") then
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.icon_file)
|
||||
esta_barra.icone_classe:SetTexCoord (0.25, 0.49609375, 0.75, 1)
|
||||
esta_barra.icone_classe:SetVertexColor (actor_class_color_r, actor_class_color_g, actor_class_color_b)
|
||||
|
||||
else
|
||||
if (instancia.row_info.use_spec_icons) then
|
||||
if (self.spec) then
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.spec_file)
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (_detalhes.class_specs_coords [self.spec]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture ([[Interface\AddOns\Details\images\classes_small]])
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (CLASS_ICON_TCOORDS [self.classe]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
end
|
||||
else
|
||||
esta_barra.icone_classe:SetTexture (instancia.row_info.icon_file)
|
||||
esta_barra.icone_classe:SetTexCoord (_unpack (CLASS_ICON_TCOORDS [self.classe]))
|
||||
esta_barra.icone_classe:SetVertexColor (1, 1, 1)
|
||||
end
|
||||
end
|
||||
--icon
|
||||
self:SetClassIcon (esta_barra.icone_classe, instancia)
|
||||
|
||||
--texture and text
|
||||
|
||||
|
||||
@@ -750,6 +750,58 @@
|
||||
end
|
||||
end
|
||||
|
||||
local string_arena_enemyteam_damage = [[
|
||||
local combat = _detalhes:GetCombat ("current")
|
||||
local total = 0
|
||||
|
||||
for _, actor in combat[1]:ListActors() do
|
||||
if (actor.arena_enemy) then
|
||||
total = total + actor.total
|
||||
end
|
||||
end
|
||||
|
||||
return total
|
||||
]]
|
||||
|
||||
local string_arena_myteam_damage = [[
|
||||
local combat = _detalhes:GetCombat ("current")
|
||||
local total = 0
|
||||
|
||||
for _, actor in combat[1]:ListActors() do
|
||||
if (actor.arena_ally) then
|
||||
total = total + actor.total
|
||||
end
|
||||
end
|
||||
|
||||
return total
|
||||
]]
|
||||
|
||||
local string_arena_enemyteam_heal = [[
|
||||
local combat = _detalhes:GetCombat ("current")
|
||||
local total = 0
|
||||
|
||||
for _, actor in combat[2]:ListActors() do
|
||||
if (actor.arena_enemy) then
|
||||
total = total + actor.total
|
||||
end
|
||||
end
|
||||
|
||||
return total
|
||||
]]
|
||||
|
||||
local string_arena_myteam_heal = [[
|
||||
local combat = _detalhes:GetCombat ("current")
|
||||
local total = 0
|
||||
|
||||
for _, actor in combat[2]:ListActors() do
|
||||
if (actor.arena_ally) then
|
||||
total = total + actor.total
|
||||
end
|
||||
end
|
||||
|
||||
return total
|
||||
]]
|
||||
|
||||
function _detalhes:CreateArenaSegment()
|
||||
|
||||
_detalhes:GetPlayersInArena()
|
||||
@@ -761,12 +813,20 @@
|
||||
_detalhes:SairDoCombate()
|
||||
end
|
||||
|
||||
--> registra os gráficos
|
||||
_detalhes:TimeDataRegister ("Your Team Damage", string_arena_myteam_damage, nil, "Details!", "v1.0", [[Interface\ICONS\Ability_DualWield]], true, true)
|
||||
_detalhes:TimeDataRegister ("Enemy Team Damage", string_arena_enemyteam_damage, nil, "Details!", "v1.0", [[Interface\ICONS\Ability_DualWield]], true, true)
|
||||
|
||||
_detalhes:TimeDataRegister ("Your Team Healing", string_arena_myteam_heal, nil, "Details!", "v1.0", [[Interface\ICONS\Ability_DualWield]], true, true)
|
||||
_detalhes:TimeDataRegister ("Enemy Team Healing", string_arena_enemyteam_heal, nil, "Details!", "v1.0", [[Interface\ICONS\Ability_DualWield]], true, true)
|
||||
|
||||
--> inicia um novo combate
|
||||
_detalhes:EntrarEmCombate()
|
||||
|
||||
--> sinaliza que esse combate é arena
|
||||
_detalhes.tabela_vigente.arena = true
|
||||
_detalhes.tabela_vigente.is_arena = {name = _detalhes.zone_name, zone = _detalhes.zone_name, mapid = _detalhes.zone_id}
|
||||
|
||||
end
|
||||
|
||||
function _detalhes:StartArenaSegment (...)
|
||||
@@ -802,6 +862,13 @@
|
||||
if (_detalhes.start_arena) then
|
||||
_detalhes:CancelTimer (_detalhes.start_arena, true)
|
||||
end
|
||||
|
||||
_detalhes:TimeDataUnregister ("Your Team Damage")
|
||||
_detalhes:TimeDataUnregister ("Enemy Team Damage")
|
||||
|
||||
_detalhes:TimeDataUnregister ("Your Team Healing")
|
||||
_detalhes:TimeDataUnregister ("Enemy Team Healing")
|
||||
|
||||
end
|
||||
|
||||
function _detalhes:MakeEqualizeOnActor (player, realm, receivedActor)
|
||||
|
||||
@@ -144,6 +144,8 @@
|
||||
--spellid, spellname, spelltype
|
||||
end
|
||||
|
||||
-- /run local f=CreateFrame("frame");f:RegisterAllEvents();f:SetScript("OnEvent", function(self, ...)print (...);end)
|
||||
|
||||
-- /run local f=CreateFrame("frame");f:RegisterEvent("COMBAT_LOG_EVENT_UNFILTERED");f:SetScript("OnEvent", function(self, ...)print (...);end)
|
||||
-- /run local f=CreateFrame("frame");f:RegisterEvent("COMBAT_LOG_EVENT_UNFILTERED");f:SetScript("OnEvent",function(self, ...) local a = select(6, ...);if (a=="<chr name>")then print (...) end end)
|
||||
|
||||
|
||||
@@ -79,6 +79,7 @@
|
||||
|
||||
end
|
||||
|
||||
--matrix = table containing {max_value = 0, last_value = 0}
|
||||
function _detalhes:TimeDataRegister (name, func, matrix, author, version, icon, is_enabled, force_no_save)
|
||||
|
||||
--> check name
|
||||
|
||||
@@ -4332,6 +4332,8 @@ local target_on_enter = function (self)
|
||||
meu_tempo = info.instancia.showing:GetCombatTime()
|
||||
end
|
||||
|
||||
local SelectedToKFunction = _detalhes.ToKFunctions [_detalhes.ps_abbreviation]
|
||||
|
||||
for index, target in ipairs (ActorTargetsSortTable) do
|
||||
if (target [2] > 0) then
|
||||
local class = _detalhes:GetClass (target [1])
|
||||
@@ -4340,13 +4342,13 @@ local target_on_enter = function (self)
|
||||
if (info.target_persecond) then
|
||||
GameTooltip:AddDoubleLine (index .. ". |TInterface\\AddOns\\Details\\images\\classes_small_alpha:14:14:0:0:128:128:"..cords[1]*128 ..":"..cords[2]*128 ..":"..cords[3]*128 ..":"..cords[4]*128 .."|t " .. target [1], _detalhes:comma_value ( _math_floor (target [2] / meu_tempo) ), 1, 1, 1, 1, 1, 1)
|
||||
else
|
||||
GameTooltip:AddDoubleLine (index .. ". |TInterface\\AddOns\\Details\\images\\classes_small_alpha:14:14:0:0:128:128:"..cords[1]*128 ..":"..cords[2]*128 ..":"..cords[3]*128 ..":"..cords[4]*128 .."|t " .. target [1], _detalhes:comma_value (target [2]), 1, 1, 1, 1, 1, 1)
|
||||
GameTooltip:AddDoubleLine (index .. ". |TInterface\\AddOns\\Details\\images\\classes_small_alpha:14:14:0:0:128:128:"..cords[1]*128 ..":"..cords[2]*128 ..":"..cords[3]*128 ..":"..cords[4]*128 .."|t " .. target [1], SelectedToKFunction (_, target [2]), 1, 1, 1, 1, 1, 1)
|
||||
end
|
||||
else
|
||||
if (info.target_persecond) then
|
||||
GameTooltip:AddDoubleLine (index .. ". " .. target [1], _detalhes:comma_value ( _math_floor (target [2] / meu_tempo)), 1, 1, 1, 1, 1, 1)
|
||||
else
|
||||
GameTooltip:AddDoubleLine (index .. ". " .. target [1], _detalhes:comma_value (target [2]), 1, 1, 1, 1, 1, 1)
|
||||
GameTooltip:AddDoubleLine (index .. ". " .. target [1], SelectedToKFunction (_, target [2]), 1, 1, 1, 1, 1, 1)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user