- Plugin 'Damage Rank': is now called 'Damage, the Game!' and was its levels adjusted to WoD.

- Plugin 'Tiny Threat': fixed player name where it was showing the realm name too.
- Plugin 'Vanguard': fixed frame details (clicking on a bar) shown behind the Vanguard panel.
- Plugin 'Vanguard': fixed a problem when clicking with right button wasn't opening the bookmark panel.
- Plugin 'Vanguard': incoming heals now count shield amount on the player too.
- Plugin 'Vanguard' Known Bug: incoming damage and melee vs avoidance seems to be inaccurate by now, we need more time to study and fix it.

- Added Twins Ogron's Charge as custom spells, one for the charge by him self and other for the copies (mythic only).

- Fixed few issues when using class text colors.
- Fixed characters name outside instances, now it replaces the realm name with a * and show the complete name on tooltip.
- Fixed damage mitigation on damage taken, this affects only specific classes like monk tank.
- Fixed auto erase poping up when the player enters on its garrison.
- Fixed segments tooltip showing trash cleanup segments inside garrisons.
- Fixed command /details disable, wasn't disabling the capture of cooldowns.
- Fixed a problem with fast dps/hps when the window is in a empty segment.
- Fixed an issue using bookmark panel where it wasn't changing the display when the window is in a plugin mode.
This commit is contained in:
Tercio
2015-01-05 23:23:25 -02:00
parent 8b0c893bde
commit faaf6380ae
18 changed files with 181 additions and 128 deletions
+21 -36
View File
File diff suppressed because one or more lines are too long
+7 -2
View File
@@ -156,7 +156,7 @@
local ignored_enemy_npcs = {
[31216] = true, --mirror image
[53006] = true, --spirit link totem
[2] = true,
[63508] = true, --xuen
}
-- Night-Twisted Brute - Creature-0-3024-1228-19402-85241-00001E2097
@@ -520,6 +520,9 @@
esta_barra.texto_esquerdo:SetText (colocacao .. ". " .. tabela [1])
esta_barra.texto_direita:SetText (tabela [2] .. " (" .. porcentagem .. "%)")
esta_barra.texto_esquerdo:SetTextColor (1, 1, 1, 1)
esta_barra.texto_direita:SetTextColor (1, 1, 1, 1)
esta_barra.texto_esquerdo:SetSize (esta_barra:GetWidth() - esta_barra.texto_direita:GetStringWidth() - 20, 15)
if (colocacao == 1) then
@@ -708,7 +711,6 @@
local total = instancia.showing.totals.voidzone_damage
local combat_time = instancia.showing:GetCombatTime()
local dps = _math_floor (self.damage / combat_time)
@@ -732,6 +734,9 @@
esta_barra.texto_esquerdo:SetText (colocacao .. ". " .. self.nome)
esta_barra.texto_esquerdo:SetSize (esta_barra:GetWidth() - esta_barra.texto_direita:GetStringWidth() - 20, 15)
esta_barra.texto_esquerdo:SetTextColor (1, 1, 1, 1)
esta_barra.texto_direita:SetTextColor (1, 1, 1, 1)
esta_barra:SetValue (100)
if (esta_barra.hidden or esta_barra.fading_in or esta_barra.faded) then
+7
View File
@@ -479,6 +479,13 @@ function atributo_misc:DeadAtualizarBarra (morte, qual_barra, colocacao, instanc
if (instancia.row_info.texture_background_class_color) then
esta_barra.background:SetVertexColor (_unpack (_detalhes.class_colors [morte[4]]))
end
if (instancia.row_info.textL_class_colors) then
esta_barra.texto_esquerdo:SetTextColor (_unpack (_detalhes.class_colors [morte[4]]))
end
if (instancia.row_info.textR_class_colors) then
esta_barra.texto_direita:SetTextColor (_unpack (_detalhes.class_colors [morte[4]]))
end
esta_barra.icone_classe:SetTexture (instancia.row_info.icon_file)
esta_barra.icone_classe:SetTexCoord (_unpack (CLASS_ICON_TCOORDS [morte[4]]))
+5
View File
@@ -150,8 +150,13 @@
novo_objeto.displayName = _detalhes:GetNickname (serial, false, true) --> serial, default, silent
if (not novo_objeto.displayName) then
if (_IsInInstance() and _detalhes.remove_realm_from_name) then
novo_objeto.displayName = nome:gsub (("%-.*"), "")
elseif (_detalhes.remove_realm_from_name) then
novo_objeto.displayName = nome:gsub (("%-.*"), "%*")
else
novo_objeto.displayName = nome
end
+11 -3
View File
@@ -53,7 +53,9 @@
function _detalhes:FindEnemy()
local ZoneName, InstanceType, DifficultyID, _, _, _, _, ZoneMapID = _GetInstanceInfo()
if (InstanceType == "party" or InstanceType == "raid") then
local in_instance = IsInInstance() --> garrison returns party as instance type.
if ((InstanceType == "party" or InstanceType == "raid") and in_instance) then
return Loc ["STRING_SEGMENT_TRASH"]
end
@@ -1045,14 +1047,20 @@
if (t) then
if (esta_barra.minha_tabela.serial and esta_barra.minha_tabela.serial ~= "") then
local avatar = NickTag:GetNicknameTable (esta_barra.minha_tabela.serial, true)
if (objeto.serial and objeto.serial ~= "") then
local avatar = NickTag:GetNicknameTable (objeto.serial, true)
if (avatar) then
if (avatar [2] and avatar [4] and avatar [1]) then
GameCooltip:SetBannerImage (1, avatar [2], 80, 40, avatarPoint, avatarTexCoord, nil) --> overlay [2] avatar path
GameCooltip:SetBannerImage (2, avatar [4], 200, 55, backgroundPoint, avatar [5], avatar [6]) --> background
GameCooltip:SetBannerText (1, avatar [1], textPoint) --> text [1] nickname
end
else
if (_detalhes.remove_realm_from_name and objeto.displayName:find ("%*")) then
GameCooltip:SetBannerImage (1, [[Interface\AddOns\Details\images\background]], 20, 30, avatarPoint, avatarTexCoord, {0, 0, 0, 0}) --> overlay [2] avatar path
GameCooltip:SetBannerImage (2, [[Interface\PetBattles\Weather-BurntEarth]], 160, 30, {{"bottomleft", "topleft", 0, -5}, {"bottomright", "topright", 0, -5}}, {0.12, 0.88, 1, 0}, {0, 0, 0, 0.1}) --> overlay [2] avatar path {0, 0, 0, 0}
GameCooltip:SetBannerText (1, objeto.nome, {"left", "left", 11, -8}, {1, 1, 1, 0.7}, 10, SharedMedia:Fetch ("font", _detalhes.tooltip.fontface)) --> text [1] nickname
end
end
end
+10 -1
View File
@@ -83,6 +83,8 @@
--combate_overall.end_time = _tempo
combate_overall.end_time = GetTime()
local is_in_instance = select (1, IsInInstance())
--> inicia a recuperação das tabelas e montagem do overall
if (#tabelas_do_historico > 0) then
for index, combate in _ipairs (tabelas_do_historico) do
@@ -110,7 +112,14 @@
for _, esta_classe in _ipairs (atributo) do
local nome = esta_classe.nome
esta_classe.displayName = nome:gsub (("%-.*"), "")
if (is_in_instance and _detalhes.remove_realm_from_name) then
esta_classe.displayName = nome:gsub (("%-.*"), "")
elseif (_detalhes.remove_realm_from_name) then
esta_classe.displayName = nome:gsub (("%-.*"), "%*")
else
esta_classe.displayName = nome
end
local shadow
+12 -7
View File
@@ -161,6 +161,7 @@
who_name = "[*] "..spellname
end
local real_damage = amount or 0
if (absorbed) then
amount = absorbed + (amount or 0)
end
@@ -304,7 +305,7 @@
this_event [1] = true --> true if this is a damage || false for healing
this_event [2] = spellid --> spellid || false if this is a battle ress line
this_event [3] = amount --> amount of damage or healing
this_event [3] = real_damage --> amount of damage or healing
this_event [4] = time --> parser time
this_event [5] = _UnitHealth (alvo_name) --> current unit heal
this_event [6] = who_name --> source name
@@ -373,7 +374,7 @@
--> damage taken
--> target
jogador_alvo.damage_taken = jogador_alvo.damage_taken + amount --> adiciona o dano tomado
jogador_alvo.damage_taken = jogador_alvo.damage_taken + real_damage --> adiciona o dano tomado
if (not jogador_alvo.damage_from [who_name]) then --> adiciona a pool de dano tomado de quem
jogador_alvo.damage_from [who_name] = true
end
@@ -418,8 +419,10 @@
--> firendly fire
if (
(_bit_band (alvo_flags, REACTION_FRIENDLY) ~= 0 and _bit_band (who_flags, REACTION_FRIENDLY) ~= 0) or
(raid_members_cache [who_serial] and raid_members_cache [alvo_serial])
--(
(_bit_band (alvo_flags, REACTION_FRIENDLY) ~= 0 and _bit_band (who_flags, REACTION_FRIENDLY) ~= 0) or --ajdt d' brx
(raid_members_cache [who_serial] and raid_members_cache [alvo_serial]) --amrl
--) and who_name ~= alvo_name
) then
--> record death log
@@ -435,7 +438,7 @@
this_event [1] = true --> true if this is a damage || false for healing
this_event [2] = spellid --> spellid || false if this is a battle ress line
this_event [3] = amount --> amount of damage or healing
this_event [3] = real_damage --> amount of damage or healing
this_event [4] = time --> parser time
this_event [5] = _UnitHealth (alvo_name) --> current unit heal
this_event [6] = who_name --> source name
@@ -2532,8 +2535,7 @@
_detalhes:EnteredInArena()
else
if (zoneType == "raid" or zoneType == "party") then
if ((zoneType == "raid" or zoneType == "party") and select (1, IsInInstance())) then
_detalhes:CheckForAutoErase (zoneMapID)
end
@@ -2996,6 +2998,9 @@
local funcao = token_list [token]
if (funcao) then
--if (token ~= "SPELL_AURA_REFRESH" and token ~= "SPELL_AURA_REMOVED" and token ~= "SPELL_AURA_APPLIED") then
-- print ("running func:", token)
--end
return funcao (nil, token, time, who_serial, who_name, who_flags, alvo_serial, alvo_name, alvo_flags, ... )
else
return
+4
View File
@@ -39,6 +39,8 @@ function SlashCmdList.DETAILS (msg, editbox)
_detalhes:CaptureSet (false, "energy", true)
_detalhes:CaptureSet (false, "miscdata", true)
_detalhes:CaptureSet (false, "aura", true)
_detalhes:CaptureSet (false, "spellcast", true)
print (Loc ["STRING_DETAILS1"] .. Loc ["STRING_SLASH_CAPTUREOFF"])
elseif (command == Loc ["STRING_SLASH_ENABLE"] or command == "enable") then
@@ -48,6 +50,8 @@ function SlashCmdList.DETAILS (msg, editbox)
_detalhes:CaptureSet (true, "energy", true)
_detalhes:CaptureSet (true, "miscdata", true)
_detalhes:CaptureSet (true, "aura", true)
_detalhes:CaptureSet (true, "spellcast", true)
print (Loc ["STRING_DETAILS1"] .. Loc ["STRING_SLASH_CAPTUREON"])
elseif (command == Loc ["STRING_SLASH_OPTIONS"] or command == "options" or command == "config") then
+3
View File
@@ -72,6 +72,9 @@ do
[158417] = {name = GetSpellInfo (158417) .. " (" .. Loc ["STRING_WAVE"] .. " #2)"}, --> Twins Ogron Pulverize waves.
[158420] = {name = GetSpellInfo (158420) .. " (" .. Loc ["STRING_WAVE"] .. " #3)"}, --> Twins Ogron Pulverize waves.
[158159] = {name = GetSpellInfo (158159) .. ""}, --> Twins Ogron Charge.
[177608] = {name = GetSpellInfo (177608) .. " (copies)"}, --> Twins Ogron Charge.
[59638] = {name = GetSpellInfo (59638) .. " (" .. Loc ["STRING_MIRROR_IMAGE"] .. ")"}, --> Mirror Image's Frost Bolt (mage)
[88082] = {name = GetSpellInfo (88082) .. " (" .. Loc ["STRING_MIRROR_IMAGE"] .. ")"}, --> Mirror Image's Fireball (mage)
+15
View File
@@ -3981,6 +3981,9 @@ function window:CreateFrame2()
frame2.damageCaptureSlider:SetPoint ("left", frame2.damageCaptureLabel, "right", 2)
frame2.damageCaptureSlider.OnSwitch = function (self, _, value)
_detalhes:CaptureSet (value, "damage", true)
if (value) then
_detalhes:CaptureSet (true, "spellcast", true)
end
switch_icon_color (frame2.damageCaptureImage, value)
end
switch_icon_color (frame2.damageCaptureImage, _detalhes.capture_real ["damage"])
@@ -3991,6 +3994,9 @@ function window:CreateFrame2()
frame2.healCaptureSlider:SetPoint ("left", frame2.healCaptureLabel, "right", 2)
frame2.healCaptureSlider.OnSwitch = function (self, _, value)
_detalhes:CaptureSet (value, "heal", true)
if (value) then
_detalhes:CaptureSet (true, "spellcast", true)
end
switch_icon_color (frame2.healCaptureImage, value)
end
switch_icon_color (frame2.healCaptureImage, _detalhes.capture_real ["heal"])
@@ -4002,6 +4008,9 @@ function window:CreateFrame2()
frame2.energyCaptureSlider.OnSwitch = function (self, _, value)
_detalhes:CaptureSet (value, "energy", true)
if (value) then
_detalhes:CaptureSet (true, "spellcast", true)
end
switch_icon_color (frame2.energyCaptureImage, value)
end
switch_icon_color (frame2.energyCaptureImage, _detalhes.capture_real ["energy"])
@@ -4012,6 +4021,9 @@ function window:CreateFrame2()
frame2.miscCaptureSlider:SetPoint ("left", frame2.miscCaptureLabel, "right", 2)
frame2.miscCaptureSlider.OnSwitch = function (self, _, value)
_detalhes:CaptureSet (value, "miscdata", true)
if (value) then
_detalhes:CaptureSet (true, "spellcast", true)
end
switch_icon_color (frame2.miscCaptureImage, value)
end
switch_icon_color (frame2.miscCaptureImage, _detalhes.capture_real ["miscdata"])
@@ -4022,6 +4034,9 @@ function window:CreateFrame2()
frame2.auraCaptureSlider:SetPoint ("left", frame2.auraCaptureLabel, "right", 2)
frame2.auraCaptureSlider.OnSwitch = function (self, _, value)
_detalhes:CaptureSet (value, "aura", true)
if (value) then
_detalhes:CaptureSet (true, "spellcast", true)
end
switch_icon_color (frame2.auraCaptureImage, value)
end
switch_icon_color (frame2.auraCaptureImage, _detalhes.capture_real ["aura"])
+12 -7
View File
@@ -2303,7 +2303,7 @@ local function iterate_scroll_scripts (backgrounddisplay, backgroundframe, basef
end
elseif (delta < 0) then --> rolou pra baixo
local B = instancia.barraS[2]
if (B < instancia.rows_showing) then
if (B < (instancia.rows_showing or 0)) then
scrollbar:SetValue (scrollbar:GetValue() + instancia.row_height * _detalhes.scroll_speed)
else
local _, maxValue = scrollbar:GetMinMaxValues()
@@ -2332,13 +2332,13 @@ local function iterate_scroll_scripts (backgrounddisplay, backgroundframe, basef
baseframe.button_up:Disable()
return
elseif (maxValue == meu_valor) then
local min = instancia.rows_showing -instancia.rows_fit_in_window
local min = (instancia.rows_showing or 0) -instancia.rows_fit_in_window
min = min+1
if (min < 1) then
min = 1
end
instancia.barraS[1] = min
instancia.barraS[2] = instancia.rows_showing
instancia.barraS[2] = (instancia.rows_showing or 0)
instancia:AtualizaGumpPrincipal (instancia, true)
self.ultimo = meu_valor
baseframe.button_down:Disable()
@@ -2355,16 +2355,16 @@ local function iterate_scroll_scripts (backgrounddisplay, backgroundframe, basef
if (meu_valor > ultimo) then --> scroll down
local B = instancia.barraS[2]
if (B < instancia.rows_showing) then --> se o valor maximo não for o máximo de barras a serem mostradas
if (B < (instancia.rows_showing or 0)) then --> se o valor maximo não for o máximo de barras a serem mostradas
local precisa_passar = ((B+1) * instancia.row_height) - (instancia.row_height*instancia.rows_fit_in_window)
--if (meu_valor > precisa_passar) then --> o valor atual passou o valor que precisa passar pra locomover
if (true) then --> testing by pass row check
local diff = meu_valor - ultimo --> pega a diferença de H
diff = diff / instancia.row_height --> calcula quantas barras ele pulou
diff = _math_ceil (diff) --> arredonda para cima
if (instancia.barraS[2]+diff > instancia.rows_showing and ultimo > 0) then
instancia.barraS[1] = instancia.rows_showing - (instancia.rows_fit_in_window-1)
instancia.barraS[2] = instancia.rows_showing
if (instancia.barraS[2]+diff > (instancia.rows_showing or 0) and ultimo > 0) then
instancia.barraS[1] = (instancia.rows_showing or 0) - (instancia.rows_fit_in_window-1)
instancia.barraS[2] = (instancia.rows_showing or 0)
else
instancia.barraS[2] = instancia.barraS[2]+diff
instancia.barraS[1] = instancia.barraS[1]+diff
@@ -3555,6 +3555,11 @@ end
--> on update function
local fast_ps_func = function (self)
local instance = self.instance
if (not instance.showing) then
return
end
local combat_time = instance.showing:GetCombatTime()
local ps_type = _detalhes.ps_abbreviation
+4 -3
View File
@@ -218,12 +218,13 @@ function _detalhes:FastSwitch (_this)
GameCooltip:ShowCooltip()
else --> botão esquerdo
if (_detalhes.switch.current_instancia.modo == _detalhes._detalhes_props["MODO_ALONE"]) then
_detalhes.switch.current_instancia:AlteraModo (_detalhes.switch.current_instancia, _detalhes.switch.current_instancia.LastModo)
_detalhes.switch.current_instancia:AlteraModo (_detalhes.switch.current_instancia, 2)
elseif (_detalhes.switch.current_instancia.modo == _detalhes._detalhes_props["MODO_RAID"]) then
_detalhes.switch.current_instancia:AlteraModo (_detalhes.switch.current_instancia, _detalhes.switch.current_instancia.LastModo)
_detalhes.switch.current_instancia:AlteraModo (_detalhes.switch.current_instancia, 2)
end
_detalhes.switch.current_instancia:TrocaTabela (_detalhes.switch.current_instancia, true, _this.atributo, _this.sub_atributo)
+28 -44
View File
@@ -27,7 +27,7 @@ local function CreatePluginFrames (data)
--local
--> default rank table
DmgRank.rank = data or {level = 1, dps = 0, dpshistory = {}, lasttry = {}, annouce = true}
DmgRank.rank = DmgRank.db
--DmgRank.rank.level = 20
--> OnEvent Table
@@ -44,7 +44,6 @@ local function CreatePluginFrames (data)
elseif (event == "COMBAT_PLAYER_TIMESTARTED") then --> combat started
--print ("recebeu event start")
local combat = select (1, ...)
--print (combat)
DmgRank:Start()
elseif (event == "PLUGIN_DISABLED") then
@@ -63,34 +62,34 @@ local function CreatePluginFrames (data)
DmgRank.TimeGoal = {
--> The 30 seconds Trial
{time = 30, damage = 1500000, name = Loc ["CHALLENGENAME_1"]}, -- Ready to Raid -- rank 2 --> -- Patrulha --> 50K DPS required
{time = 30, damage = 1800000, name = Loc ["CHALLENGENAME_2"]}, -- Damage Practice --rank 3 --> -- Soldier --> 60K DPS required
{time = 30, damage = 2100000, name = Loc ["CHALLENGENAME_3"]}, -- The Training Continue... -- rank 4 --> -- Corporal --> 70K DPS required
{time = 30, damage = 350000, name = Loc ["CHALLENGENAME_1"]}, -- Ready to Raid -- rank 2 --> -- Patrulha --> ~11K DPS required
{time = 30, damage = 420000, name = Loc ["CHALLENGENAME_2"]}, -- Damage Practice --rank 3 --> -- Soldier --> ~14K DPS required
{time = 30, damage = 500000, name = Loc ["CHALLENGENAME_3"]}, -- The Training Continue... -- rank 4 --> -- Corporal --> ~16K DPS required
--> 90 seconds bracket
{time = 90, damage = 5080000, name = Loc ["CHALLENGENAME_4"]}, -- You Just Need a Little More Time -- rank 5 --> -- Sergeant --> 56K DPS required
{time = 90, damage = 5814800, name = Loc ["CHALLENGENAME_5"]}, -- Became a Knight -- rank 6 --> -- Sergeant --> 64K DPS required
{time = 90, damage = 1601010, name = Loc ["CHALLENGENAME_4"]}, -- You Just Need a Little More Time -- rank 5 --> -- Sergeant --> ~17K DPS required
{time = 90, damage = 1666660, name = Loc ["CHALLENGENAME_5"]}, -- Became a Knight -- rank 6 --> -- Sergeant --> ~18K DPS required
--> middle bracket
{time = 120, damage = 7901760, name = Loc ["CHALLENGENAME_6"]}, -- Two Minutes -- rank 7 --> Iron Knight --> 65K DPS required
{time = 120, damage = 8442112, name = Loc ["CHALLENGENAME_7"]}, --rank 8 --> Steel Knight --> 70K DPS required
{time = 180, damage = 13452000, name = Loc ["CHALLENGENAME_8"]}, --rank 9 --> --> The High Knight --> 74K DPS required
{time = 180, damage = 14152100, name = Loc ["CHALLENGENAME_9"]}, --rank 10 --> Yes Sir! -- Thorium Knight --> 78K DPS required
{time = 180, damage = 15052100, name = Loc ["CHALLENGENAME_10"]}, --rank 11 --> Salute -- Silver Lieutenant --> 83K DPS required
{time = 120, damage = 2254120, name = Loc ["CHALLENGENAME_6"]}, -- Two Minutes -- rank 7 --> Iron Knight --> ~18K DPS required
{time = 120, damage = 2409500, name = Loc ["CHALLENGENAME_7"]}, --rank 8 --> Steel Knight --> ~20K DPS required
{time = 180, damage = 3390000, name = Loc ["CHALLENGENAME_8"]}, --rank 9 --> --> The High Knight --> ~18K DPS required
{time = 180, damage = 3499000, name = Loc ["CHALLENGENAME_9"]}, --rank 10 --> Yes Sir! -- Thorium Knight --> ~19K DPS required
{time = 180, damage = 3784051, name = Loc ["CHALLENGENAME_10"]}, --rank 11 --> Salute -- Silver Lieutenant --> ~21K DPS required
--> burst bracket
{time = 40, damage = 5000000, name = Loc ["CHALLENGENAME_11"]}, --rank 12 --> In Burst We Trust -- Gold Lieutenant --> 125K DPS required
{time = 40, damage = 5700000, name = Loc ["CHALLENGENAME_12"]}, --rank 13 --> Watch me Explode -- Stone Guardian --> 142K DPS required
{time = 40, damage = 6300000, name = Loc ["CHALLENGENAME_13"]}, --rank 14 --> T.N.T-- Fel Guardian --> 157K DPS required
{time = 40, damage = 1351144, name = Loc ["CHALLENGENAME_11"]}, --rank 12 --> In Burst We Trust -- Gold Lieutenant --> ~33K DPS required
{time = 40, damage = 1494404, name = Loc ["CHALLENGENAME_12"]}, --rank 13 --> Watch me Explode -- Stone Guardian --> ~37K DPS required
{time = 40, damage = 1569900, name = Loc ["CHALLENGENAME_13"]}, --rank 14 --> T.N.T-- Fel Guardian --> ~39K DPS required
--> long run bracket
{time = 300, damage = 35052100, name = Loc ["CHALLENGENAME_14"]}, --rank 15 --> Time is Damage My Friend -- Titan Guardian --> 116K DPS required
{time = 330, damage = 41151120, name = Loc ["CHALLENGENAME_15"]}, --rank 16 - Just a Little Patience --> Bronze Centurion --> 124K DPS required
{time = 360, damage = 47395100, name = Loc ["CHALLENGENAME_16"]}, --rank 17 --> Silver Centurion --> 131K DPS required
{time = 300, damage = 6211201, name = Loc ["CHALLENGENAME_14"]}, --rank 15 --> Time is Damage My Friend -- Titan Guardian --> ~20K DPS required
{time = 300, damage = 6842459, name = Loc ["CHALLENGENAME_15"]}, --rank 16 - Just a Little Patience --> Bronze Centurion --> ~22K DPS required
{time = 300, damage = 7511983, name = Loc ["CHALLENGENAME_16"]}, --rank 17 --> Silver Centurion --> ~25K DPS required
{time = 300, damage = 56911000, name = Loc ["CHALLENGENAME_17"]}, --rank 18 --> Flame Centurion --> ?K DPS required
{time = 360, damage = 71821980, name = Loc ["CHALLENGENAME_18"]}, --rank 19 --> Lower Vanquisher --> ?K DPS required
{time = 180, damage = 45910990, name = Loc ["CHALLENGENAME_19"]}, --rank 20 --> Middle Vanquisher --> ?K DPS required
{time = 120, damage = 4011100, name = Loc ["CHALLENGENAME_17"]}, --rank 18 --> Flame Centurion --> ~33K DPS required
{time = 120, damage = 4300000, name = Loc ["CHALLENGENAME_18"]}, --rank 19 --> Lower Vanquisher --> 35K DPS required
{time = 60, damage = 2650000, name = Loc ["CHALLENGENAME_19"]}, --rank 20 --> Middle Vanquisher --> 44K DPS required
--> end
{time = nil, damage = nil, name = ""}, --rank 21 --> none
@@ -237,23 +236,6 @@ local function CreatePluginFrames (data)
background:SetDrawLayer ("background", 1)
DmgRank.BackgroundTex = background
local AnimeFrame = CreateFrame ("frame", nil, DmgRankFrame)
AnimeFrame:SetAllPoints (DmgRankFrame)
local background2 = AnimeFrame:CreateTexture (nil, "background")
background2:SetTexture ("Interface\\AddOns\\Details_DmgRank\\solo_bgtimeattack")
background2:SetPoint ("topleft", DmgRankFrame, "topleft", 2, 0)
background2:SetPoint ("bottomright", DmgRankFrame, "bottomright", -2, 0)
DmgRank.BackgroundTex2 = background2
background2:SetDrawLayer ("background", 2)
local RotateAnimGroup = AnimeFrame:CreateAnimationGroup()
local rotate = RotateAnimGroup:CreateAnimation ("Rotation")
rotate:SetDegrees (360)
rotate:SetDuration (120)
RotateAnimGroup:SetLooping ("repeat")
RotateAnimGroup:Play()
--> next rank at display
local challengeName = DetailsFrameWork:NewLabel (DmgRankFrame, DmgRankFrame, nil, "challengeName", "", "QuestFont_Shadow_Huge")
challengeName:SetPoint ("center", DmgRankFrame, "center")
@@ -486,7 +468,7 @@ local function CreatePluginFrames (data)
DmgRank.rank.level = DmgRank.rank.level + 1
if (DmgRank.rank.annouce) then
SendChatMessage (UnitName ("player") .. " " .. Loc ["STRING_ANNOUNCE_STRING"] .. " " .. DmgRank.rank.level .. " (" .. self.Titles [DmgRank.rank.level] .. ") " .. Loc ["STRING_ANNOUNCE_ON"] .. " Details! " .. Loc ["STRING_PLUGIN_NAME"] .. ".", "GUILD")
SendChatMessage (UnitName ("player") .. " " .. Loc ["STRING_ANNOUNCE_STRING"] .. " " .. DmgRank.rank.level .. " (" .. self.Titles [DmgRank.rank.level] .. ") " .. Loc ["STRING_ANNOUNCE_ON"] .. " Details!: " .. Loc ["STRING_PLUGIN_NAME"] .. ".", "GUILD")
end
DmgRank.rank.dps = player.total
@@ -545,17 +527,19 @@ function DmgRank:OnEvent (_, event, ...)
if (_G._detalhes) then
--> create widgets
CreatePluginFrames (_detalhes_databaseDmgRank)
local MINIMAL_DETAILS_VERSION_REQUIRED = 1
local MINIMAL_DETAILS_VERSION_REQUIRED = 50
local default_config = {level = 1, dps = 0, dpshistory = {}, lasttry = {}, annouce = true}
--> Install plugin inside details
local install, saveddata = _G._detalhes:InstallPlugin ("SOLO", Loc ["STRING_PLUGIN_NAME"], "Interface\\Icons\\ACHIEVEMENT_GUILDPERK_HONORABLEMENTION_RANK2", DmgRank, "DETAILS_PLUGIN_DAMAGE_RANK", MINIMAL_DETAILS_VERSION_REQUIRED, "Details! Team", "v1.1.1")
local install, saveddata = _G._detalhes:InstallPlugin ("SOLO", Loc ["STRING_PLUGIN_NAME"], "Interface\\Icons\\ACHIEVEMENT_GUILDPERK_HONORABLEMENTION_RANK2", DmgRank, "DETAILS_PLUGIN_DAMAGE_RANK", MINIMAL_DETAILS_VERSION_REQUIRED, "Details! Team", "v1.2.0", default_config)
if (type (install) == "table" and install.error) then
print (install.error)
end
--> create widgets
CreatePluginFrames()
--> Register needed events
_G._detalhes:RegisterEvent (DmgRank, "COMBAT_PLAYER_TIMESTARTED")
+1 -2
View File
@@ -1,7 +1,6 @@
## Interface: 60000
## Title: Details DamageRank (plugin)
## Title: Details Damage, the Game! (plugin)
## Notes: Plugin for Details
## SavedVariablesPerCharacter: _detalhes_databaseDmgRank
## RequiredDeps: Details
## OptionalDeps: Ace3, LibSharedMedia-3.0, LibBossIDs-1.0, LibGraph-2.0, !ClassColors
+1 -1
View File
@@ -5,7 +5,7 @@ if (not Loc) then
end
--> Labels:
Loc ["STRING_PLUGIN_NAME"] = "Damage Rank"
Loc ["STRING_PLUGIN_NAME"] = "Damage, the Game!"
Loc ["STRING_CURRENTRANK"] = "Your current rank is:"
Loc ["STRING_ANNOUNCE"] = "announce"
Loc ["STRING_ANNOUNCE_STRING"] = "has reached the level"
+1 -1
View File
@@ -5,7 +5,7 @@ if (not Loc) then
end
--> Labels:
Loc ["STRING_PLUGIN_NAME"] = "Rank de Dano"
Loc ["STRING_PLUGIN_NAME"] = "Dano, o Jogo!"
Loc ["STRING_CURRENTRANK"] = "Seu rank atual:"
Loc ["STRING_LASTTRIES"] = "Ultimas tentativas:"
Loc ["STRING_ANNOUNCE"] = "anunciar"
@@ -52,6 +52,8 @@ local function CreatePluginFrames (data)
--> localize functions
ThreatMeter.percent_color = ThreatMeter.percent_color
ThreatMeter.GetOnlyName = ThreatMeter.GetOnlyName
--> window reference
local instance
local player
@@ -367,7 +369,6 @@ local function CreatePluginFrames (data)
pullRow:SetLeftText ("Pull Aggro At")
local realPercent = _math_floor (aggro / topThreat [6] * 100)
pullRow:SetRightText ("+" .. ThreatMeter:ToK2 (aggro - myThreat) .. " (" .. _math_floor (_math_abs ((myThreat / aggro * 100) - realPercent)) .. "%)") --
--thisRow.textleft:SetTextColor ()
pullRow:SetValue (100)
local myPercentToAggro = myThreat / aggro * 100
@@ -394,7 +395,7 @@ local function CreatePluginFrames (data)
local role = threat_actor [4]
thisRow._icon:SetTexCoord (_unpack (RoleIconCoord [role]))
thisRow:SetLeftText (threat_actor [1])
thisRow:SetLeftText (ThreatMeter:GetOnlyName (threat_actor [1]))
local pct = threat_actor [2]
+36 -19
View File
@@ -9,10 +9,12 @@ local _IsInGroup = IsInGroup --> wow api local
local _UnitAura = UnitAura --> wow api local
local _UnitName = UnitName --> wow api local
local _UnitGroupRolesAssigned = UnitGroupRolesAssigned --> wow api local
local _UnitHealth = UnitHealth --> wow api local
local _UnitHealthMax = UnitHealthMax --> wow api local
local _UnitIsPlayer = UnitIsPlayer --> wow api local
local _UnitClass = UnitClass --> wow api local
local _UnitDebuff = UnitDebuff --> wow api local
local _UnitGetIncomingHeals = UnitGetIncomingHeals
---------------------------------------------------------------------------------------------
local _cstr = string.format --> lua library local
local _table_insert = table.insert --> lua library local
@@ -22,6 +24,7 @@ local _pairs = pairs --> lua library local
local _math_floor = math.floor --> lua library local
local _math_abs = math.abs --> lua library local
local _math_min = math.min --> lua library local
local _table_sort = table.sort
---------------------------------------------------------------------------------------------
--> Create plugin Object
@@ -310,7 +313,8 @@ local function CreatePluginFrames (data)
local infoFrame = DetailsFrameWork:NewPanel (VanguardFrame, VanguardFrame, "VanguardInfoFrame", "infoFrame", 300, 100)
infoFrame:SetPoint ("topleft", VanguardFrame, "topleft")
infoFrame:Hide()
infoFrame:SetFrameLevel (5)
infoFrame:SetFrameLevel (VanguardFrame:GetFrameLevel() + 10)
VanguardFrame.InfoShown = false
infoFrame:SetBackdrop ("Interface\\DialogFrame\\UI-DialogBox-Background-Dark")
@@ -339,24 +343,33 @@ local function CreatePluginFrames (data)
ReportButton.tooltip = Loc ["STRING_REPORT_AVOIDANCE_TOOLTIP"]
infoFrame:SetHook ("OnMouseUp", function (_, button)
if (string.lower (button):find ("right")) then
--if (string.lower (button):find ("right")) then
VanguardFrame.InfoShown = false
infoFrame:Hide()
if (infoFrame.refreshTick) then
Vanguard:CancelTimer (infoFrame.refreshTick)
infoFrame.refreshTick = nil
end
end
--end
end)
local funcInfo = function()
VanguardFrame.InfoShown = true
Vanguard:VanguardRefreshInfoFrame()
local w, h = instancia:GetSize()
infoFrame.width = w
infoFrame.height = h
infoFrame:Show()
infoFrame.refreshTick = Vanguard:ScheduleRepeatingTimer ("VanguardRefreshInfoFrame", 1)
local funcInfo = function (self, button)
if (button == "LeftButton") then
VanguardFrame.InfoShown = true
Vanguard:VanguardRefreshInfoFrame()
local w, h = instancia:GetSize()
infoFrame.width = w
infoFrame.height = h
infoFrame:Show()
infoFrame.refreshTick = Vanguard:ScheduleRepeatingTimer ("VanguardRefreshInfoFrame", 1)
elseif (button == "RightButton") then
local instance = Vanguard:GetPluginInstance()
if (instance) then
_detalhes.switch:ShowMe (instance)
end
end
end
--> Info frame widgets:
@@ -456,11 +469,11 @@ local function CreatePluginFrames (data)
for actorName, _ in pairs (heal_from) do
local thisActor = Vanguard:GetActor ("current", DETAILS_ATTRIBUTE_HEAL, actorName)
local targets = thisActor.targets --> targets is a container with target classes
local amount = targets:GetAmount (_track_player_name, "total")
local amount = targets [_track_player_name] or 0
myReceivedHeal [#myReceivedHeal+1] = {actorName, amount}
end
table.sort (myReceivedHeal, Vanguard.Sort2) --> Sort2 sort by second index
_table_sort (myReceivedHeal, Vanguard.Sort2) --> Sort2 sort by second index
for i = 1, 4 do
if (myReceivedHeal[i]) then
@@ -724,7 +737,7 @@ local function CreatePluginFrames (data)
end
function Vanguard:UpdateHealth (index, unit)
local percent = UnitHealth (unit) / UnitHealthMax (unit) * 100
local percent = _UnitHealth (unit) / _UnitHealthMax (unit) * 100
Vanguard.TankFrames [index].Life (percent)
end
@@ -940,12 +953,13 @@ local function CreatePluginFrames (data)
local on_second_tick = 0
local half_second_tick = 0
-- úpdate
local onupdate = function (self, elapsed)
half_second_tick = half_second_tick + elapsed
on_second_tick = on_second_tick + elapsed
if (on_second_tick >= 1) then
if (on_second_tick >= 0.3) then
--> capture debuffs
for TankIndex, TankName in _ipairs (Vanguard.TankList) do
@@ -1008,7 +1022,7 @@ local function CreatePluginFrames (data)
on_second_tick = 0
end
if (half_second_tick > 0.5 and _track_player_object.avoidance) then
if (half_second_tick > 0.1 and _track_player_object.avoidance) then
--> capture the amount of hits and avoids
@@ -1089,8 +1103,11 @@ local function CreatePluginFrames (data)
local dmgAmt = damage_now / #damage_taken
DamageVsHeal:SetRightText (Vanguard:ToK ( _math_floor (dmgAmt)))
local IncomingHeal = UnitGetIncomingHeals (_track_player_name) or 0
DamageVsHeal:SetLeftText (Vanguard:ToK (IncomingHeal))
local shields = UnitGetTotalAbsorbs (_track_player_name) or 0
local IncomingHeal = _UnitGetIncomingHeals (_track_player_name) or 0
DamageVsHeal:SetLeftText (Vanguard:ToK (IncomingHeal + shields) .. " (|cFFFFFF55A: " .. Vanguard:ToK (shields) .. "|r)")
IncomingHeal = IncomingHeal + shields
if (dmgAmt > 0 and IncomingHeal > 0) then
if (dmgAmt > IncomingHeal) then
@@ -1125,7 +1142,7 @@ local function CreatePluginFrames (data)
local amt = 1
local hp = _UnitHealthMax (_track_player_name)/3
local last_events_table = _combat_object.player_last_events [MyName]
local last_events_table = _combat_object.player_last_events [_track_player_name or MyName] or _combat_object.player_last_events [MyName]
if (last_events_table) then
for _, tabela in _ipairs (last_events_table) do
if (tabela[1]) then