Fixed an error while trying to move the window by clicking and holding on a window line
This commit is contained in:
@@ -714,7 +714,7 @@
|
||||
end
|
||||
|
||||
--frags
|
||||
for fragName, fragAmount in pairs (combate2.frags) do
|
||||
for fragName, fragAmount in pairs(combate2.frags) do
|
||||
if (fragAmount) then
|
||||
if (combate1.frags [fragName]) then
|
||||
combate1.frags [fragName] = combate1.frags [fragName] - fragAmount
|
||||
@@ -727,7 +727,7 @@
|
||||
|
||||
--alternate power
|
||||
local overallPowerTable = combate1.alternate_power
|
||||
for actorName, powerTable in pairs (combate2.alternate_power) do
|
||||
for actorName, powerTable in pairs(combate2.alternate_power) do
|
||||
local power = overallPowerTable [actorName]
|
||||
if (power) then
|
||||
power.total = power.total - powerTable.total
|
||||
@@ -769,7 +769,7 @@
|
||||
|
||||
--alternate power
|
||||
local overallPowerTable = combate1.alternate_power
|
||||
for actorName, powerTable in pairs (combate2.alternate_power) do
|
||||
for actorName, powerTable in pairs(combate2.alternate_power) do
|
||||
local power = overallPowerTable [actorName]
|
||||
if (not power) then
|
||||
power = combate1:CreateAlternatePowerTable (actorName)
|
||||
|
||||
+26
-26
@@ -1234,7 +1234,7 @@
|
||||
--get the spell buff uptime container
|
||||
local buff_uptime_container = player.buff_uptime and player.buff_uptime_spells and player.buff_uptime_spells._ActorTable
|
||||
if (buff_uptime_container) then
|
||||
for spellId, _ in pairs (DetailsFramework.PotionIDs) do
|
||||
for spellId, _ in pairs(DetailsFramework.PotionIDs) do
|
||||
local potionUsed = buff_uptime_container [spellId]
|
||||
|
||||
if (potionUsed) then
|
||||
@@ -1282,7 +1282,7 @@
|
||||
--get the misc actor container
|
||||
local buff_uptime_container = player.buff_uptime and player.buff_uptime_spells and player.buff_uptime_spells._ActorTable
|
||||
if (buff_uptime_container) then
|
||||
for spellId, _ in pairs (DetailsFramework.PotionIDs) do
|
||||
for spellId, _ in pairs(DetailsFramework.PotionIDs) do
|
||||
local potionUsed = buff_uptime_container [spellId]
|
||||
|
||||
if (potionUsed) then
|
||||
@@ -1337,7 +1337,7 @@
|
||||
for index, character in ipairs(AllHealCharacters) do
|
||||
local AllSpells = character:GetSpellList()
|
||||
local found = false
|
||||
for spellid, spell in pairs (AllSpells) do
|
||||
for spellid, spell in pairs(AllSpells) do
|
||||
if (DETAILS_HEALTH_POTION_LIST [spellid]) then
|
||||
instance_container:AddValue (character, spell.total)
|
||||
total = total + spell.total
|
||||
@@ -1436,7 +1436,7 @@
|
||||
]],
|
||||
percent_script = [[
|
||||
local value, top, total, combat, instance = ...
|
||||
return string.format ("%.1f", value/top*100)
|
||||
return string.format("%.1f", value/top*100)
|
||||
]],
|
||||
script = [[
|
||||
--init:
|
||||
@@ -1500,7 +1500,7 @@
|
||||
]],
|
||||
percent_script = [[
|
||||
local value, top, total, combat, instance = ...
|
||||
return string.format ("%.1f", value/top*100)
|
||||
return string.format("%.1f", value/top*100)
|
||||
]],
|
||||
script = [[
|
||||
--init:
|
||||
@@ -1584,8 +1584,8 @@
|
||||
tooltip = [[
|
||||
local actor, combat, instance = ...
|
||||
local spells = {}
|
||||
for spellid, spell in pairs (actor.cc_done_spells._ActorTable) do
|
||||
tinsert (spells, {spellid, spell.counter})
|
||||
for spellid, spell in pairs(actor.cc_done_spells._ActorTable) do
|
||||
tinsert(spells, {spellid, spell.counter})
|
||||
end
|
||||
|
||||
table.sort (spells, _detalhes.Sort2)
|
||||
@@ -1598,8 +1598,8 @@
|
||||
end
|
||||
|
||||
local targets = {}
|
||||
for playername, amount in pairs (actor.cc_done_targets) do
|
||||
tinsert (targets, {playername, amount})
|
||||
for playername, amount in pairs(actor.cc_done_targets) do
|
||||
tinsert(targets, {playername, amount})
|
||||
end
|
||||
|
||||
table.sort (targets, _detalhes.Sort2)
|
||||
@@ -1644,7 +1644,7 @@
|
||||
for i, custom in ipairs(self.custom) do
|
||||
if (custom.name == Loc ["STRING_CUSTOM_CC_DONE"]) then
|
||||
table.remove (self.custom, i)
|
||||
tinsert (self.custom, i, CC_Done)
|
||||
tinsert(self.custom, i, CC_Done)
|
||||
have = true
|
||||
end
|
||||
end
|
||||
@@ -1676,7 +1676,7 @@
|
||||
for index, character in ipairs(misc_actors) do
|
||||
if (character.cc_done and character:IsPlayer()) then
|
||||
|
||||
for player_name, amount in pairs (character.cc_done_targets) do
|
||||
for player_name, amount in pairs(character.cc_done_targets) do
|
||||
local target = combat (1, player_name) or combat (2, player_name)
|
||||
if (target and target:IsPlayer()) then
|
||||
instance_container:AddValue (target, amount)
|
||||
@@ -1706,9 +1706,9 @@
|
||||
if (character.cc_done and character:IsPlayer()) then
|
||||
local on_actor = character.cc_done_targets [name]
|
||||
if (on_actor) then
|
||||
tinsert (from, {character:name(), on_actor})
|
||||
tinsert(from, {character:name(), on_actor})
|
||||
|
||||
for spellid, spell in pairs (character.cc_done_spells._ActorTable) do
|
||||
for spellid, spell in pairs(character.cc_done_spells._ActorTable) do
|
||||
|
||||
local spell_on_actor = spell.targets [name]
|
||||
if (spell_on_actor) then
|
||||
@@ -1720,7 +1720,7 @@
|
||||
end
|
||||
end
|
||||
if (not has_spell) then
|
||||
tinsert (spells, {spellid, spell_on_actor})
|
||||
tinsert(spells, {spellid, spell_on_actor})
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1778,7 +1778,7 @@
|
||||
for i, custom in ipairs(self.custom) do
|
||||
if (custom.name == Loc ["STRING_CUSTOM_CC_RECEIVED"]) then
|
||||
table.remove (self.custom, i)
|
||||
tinsert (self.custom, i, CC_Received)
|
||||
tinsert(self.custom, i, CC_Received)
|
||||
have = true
|
||||
end
|
||||
end
|
||||
@@ -1827,7 +1827,7 @@
|
||||
|
||||
if (player) then
|
||||
local spells = player:GetSpellList()
|
||||
for spellid, spell in pairs (spells) do
|
||||
for spellid, spell in pairs(spells) do
|
||||
instance_container:AddValue (spell, spell.total)
|
||||
total = total + spell.total
|
||||
if (top < spell.total) then
|
||||
@@ -1839,7 +1839,7 @@
|
||||
for _, PetName in ipairs(player.pets) do
|
||||
local pet = combat (pet_attribute, PetName)
|
||||
if (pet) then
|
||||
for spellid, spell in pairs (pet:GetSpellList()) do
|
||||
for spellid, spell in pairs(pet:GetSpellList()) do
|
||||
instance_container:AddValue (spell, spell.total, nil, " (" .. PetName:gsub ((" <.*"), "") .. ")")
|
||||
total = total + spell.total
|
||||
if (top < spell.total) then
|
||||
@@ -1895,7 +1895,7 @@
|
||||
|
||||
if (not spell_cast and misc_actor.spell_cast) then
|
||||
local spellname = GetSpellInfo(spell.id)
|
||||
for casted_spellid, amount in pairs (misc_actor.spell_cast) do
|
||||
for casted_spellid, amount in pairs(misc_actor.spell_cast) do
|
||||
local casted_spellname = GetSpellInfo(casted_spellid)
|
||||
if (casted_spellname == spellname) then
|
||||
spell_cast = amount .. " (|cFFFFFF00?|r)"
|
||||
@@ -2027,7 +2027,7 @@
|
||||
percent_script = [[
|
||||
local value, top, total, combat, instance = ...
|
||||
local dps = _detalhes:ToK (floor (value) / combat:GetCombatTime())
|
||||
local percent = string.format ("%.1f", value/total*100)
|
||||
local percent = string.format("%.1f", value/total*100)
|
||||
return dps .. ", " .. percent
|
||||
]],
|
||||
}
|
||||
@@ -2046,7 +2046,7 @@
|
||||
for i, custom in ipairs(self.custom) do
|
||||
if (custom.name == Loc ["STRING_CUSTOM_MYSPELLS"]) then
|
||||
table.remove (self.custom, i)
|
||||
tinsert (self.custom, i, MySpells)
|
||||
tinsert(self.custom, i, MySpells)
|
||||
have = true
|
||||
end
|
||||
end
|
||||
@@ -2138,7 +2138,7 @@
|
||||
for i, custom in ipairs(self.custom) do
|
||||
if (custom.name == Loc ["STRING_CUSTOM_DAMAGEONSKULL"]) then
|
||||
table.remove (self.custom, i)
|
||||
tinsert (self.custom, i, DamageOnSkullTarget)
|
||||
tinsert(self.custom, i, DamageOnSkullTarget)
|
||||
have = true
|
||||
end
|
||||
end
|
||||
@@ -2268,7 +2268,7 @@
|
||||
for i, custom in ipairs(self.custom) do
|
||||
if (custom.name == Loc ["STRING_CUSTOM_DAMAGEONANYMARKEDTARGET"]) then
|
||||
table.remove (self.custom, i)
|
||||
tinsert (self.custom, i, DamageOnAnyTarget)
|
||||
tinsert(self.custom, i, DamageOnAnyTarget)
|
||||
have = true
|
||||
end
|
||||
end
|
||||
@@ -2357,7 +2357,7 @@
|
||||
if (player) then
|
||||
playerTotal = playerTotal + player.total
|
||||
local playerSpells = player:GetSpellList()
|
||||
for spellID, spellTable in pairs (playerSpells) do
|
||||
for spellID, spellTable in pairs(playerSpells) do
|
||||
AllSpells [spellID] = spellTable.total
|
||||
end
|
||||
end
|
||||
@@ -2367,15 +2367,15 @@
|
||||
if (player) then
|
||||
playerTotal = playerTotal + player.total
|
||||
local playerSpells = player:GetSpellList()
|
||||
for spellID, spellTable in pairs (playerSpells) do
|
||||
for spellID, spellTable in pairs(playerSpells) do
|
||||
AllSpells [spellID] = (AllSpells [spellID] or 0) + (spellTable.total or 0)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
local sortedList = {}
|
||||
for spellID, total in pairs (AllSpells) do
|
||||
tinsert (sortedList, {spellID, total})
|
||||
for spellID, total in pairs(AllSpells) do
|
||||
tinsert(sortedList, {spellID, total})
|
||||
end
|
||||
table.sort (sortedList, Details.Sort2)
|
||||
|
||||
|
||||
+38
-38
@@ -685,7 +685,7 @@ end
|
||||
Details:AddTooltipReportLineText()
|
||||
|
||||
GameCooltip:SetOption("YSpacingMod", 0)
|
||||
GameCooltip:SetOwner (thisLine)
|
||||
GameCooltip:SetOwner(thisLine)
|
||||
GameCooltip:Show()
|
||||
|
||||
end
|
||||
@@ -695,7 +695,7 @@ end
|
||||
end
|
||||
|
||||
local on_switch_DTBS_show = function(instance)
|
||||
instance:TrocaTabela (instance, true, 1, 8)
|
||||
instance:TrocaTabela(instance, true, 1, 8)
|
||||
return true
|
||||
end
|
||||
|
||||
@@ -882,7 +882,7 @@ end
|
||||
if (not CustomObject.OnSwitchShow) then
|
||||
CustomObject.OnSwitchShow = on_switch_DTBS_show
|
||||
end
|
||||
return instance:TrocaTabela (instance.segmento, 5, index)
|
||||
return instance:TrocaTabela(instance.segmento, 5, index)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -906,11 +906,11 @@ end
|
||||
new_code = new_code:gsub ("@SPELLID@", spell [1])
|
||||
new_custom_object.script = new_code
|
||||
|
||||
tinsert (Details.custom, new_custom_object)
|
||||
tinsert(Details.custom, new_custom_object)
|
||||
setmetatable (new_custom_object, Details.atributo_custom)
|
||||
new_custom_object.__index = Details.atributo_custom
|
||||
|
||||
return instance:TrocaTabela (instance.segmento, 5, #Details.custom)
|
||||
return instance:TrocaTabela(instance.segmento, 5, #Details.custom)
|
||||
end
|
||||
|
||||
local DTBS_format_name = function(player_name) return Details:GetOnlyName (player_name) end
|
||||
@@ -1210,7 +1210,7 @@ end
|
||||
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
--void zones
|
||||
local on_switch_AVZ_show = function(instance)
|
||||
instance:TrocaTabela (instance, true, 1, 7)
|
||||
instance:TrocaTabela(instance, true, 1, 7)
|
||||
return true
|
||||
end
|
||||
|
||||
@@ -1260,7 +1260,7 @@ end
|
||||
local t = tooltip_void_zone_temp [i]
|
||||
if (not t) then
|
||||
t = {}
|
||||
tinsert (tooltip_void_zone_temp, t)
|
||||
tinsert(tooltip_void_zone_temp, t)
|
||||
end
|
||||
|
||||
local target_actor = combat (1, target_name) or combat (2, target_name) or combat (4, target_name)
|
||||
@@ -1319,7 +1319,7 @@ end
|
||||
if (not CustomObject.OnSwitchShow) then
|
||||
CustomObject.OnSwitchShow = on_switch_AVZ_show
|
||||
end
|
||||
return instance:TrocaTabela (instance.segmento, 5, index)
|
||||
return instance:TrocaTabela(instance.segmento, 5, index)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1348,11 +1348,11 @@ end
|
||||
new_total_code = new_total_code:gsub ("@SPELLID@", spellid)
|
||||
new_custom_object.total_script = new_total_code
|
||||
|
||||
tinsert (Details.custom, new_custom_object)
|
||||
tinsert(Details.custom, new_custom_object)
|
||||
setmetatable (new_custom_object, Details.atributo_custom)
|
||||
new_custom_object.__index = Details.atributo_custom
|
||||
|
||||
return instance:TrocaTabela (instance.segmento, 5, #Details.custom)
|
||||
return instance:TrocaTabela(instance.segmento, 5, #Details.custom)
|
||||
end
|
||||
|
||||
function atributo_damage:ReportSingleVoidZoneLine (actor, instance, ShiftKeyDown, ControlKeyDown)
|
||||
@@ -1448,7 +1448,7 @@ end
|
||||
local t = tooltip_void_zone_temp [i]
|
||||
if (not t) then
|
||||
t = {}
|
||||
tinsert (tooltip_void_zone_temp, t)
|
||||
tinsert(tooltip_void_zone_temp, t)
|
||||
end
|
||||
|
||||
t[1] = target_name
|
||||
@@ -2279,16 +2279,16 @@ function atributo_damage:RefreshWindow (instancia, combatObject, forcar, exporta
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
for i = instancia.barraS[1], iterLast-1, 1 do
|
||||
if (actorTableContent[i]) then
|
||||
actorTableContent[i]:RefreshLine (instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[i]:RefreshLine(instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
actorTableContent[myPos]:RefreshLine (instancia, lineContainer, whichRowLine, myPos, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[myPos]:RefreshLine(instancia, lineContainer, whichRowLine, myPos, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
else
|
||||
for i = instancia.barraS[1], iterLast, 1 do
|
||||
if (actorTableContent[i]) then
|
||||
actorTableContent[i]:RefreshLine (instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[i]:RefreshLine(instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
@@ -2298,18 +2298,18 @@ function atributo_damage:RefreshWindow (instancia, combatObject, forcar, exporta
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
for i = instancia.barraS[1], instancia.barraS[2]-1, 1 do
|
||||
if (actorTableContent[i]) then
|
||||
actorTableContent[i]:RefreshLine (instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[i]:RefreshLine(instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
|
||||
actorTableContent[myPos]:RefreshLine (instancia, lineContainer, whichRowLine, myPos, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[myPos]:RefreshLine(instancia, lineContainer, whichRowLine, myPos, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
else
|
||||
for i = instancia.barraS[1], instancia.barraS[2], 1 do
|
||||
if (actorTableContent[i]) then
|
||||
|
||||
actorTableContent[i]:RefreshLine (instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[i]:RefreshLine(instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
@@ -2349,29 +2349,29 @@ function atributo_damage:RefreshWindow (instancia, combatObject, forcar, exporta
|
||||
totalBarIsShown = true
|
||||
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
actorTableContent[myPos]:RefreshLine (instancia, lineContainer, whichRowLine, myPos, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[myPos]:RefreshLine(instancia, lineContainer, whichRowLine, myPos, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
for i = iter_last-1, instancia.barraS[1], -1 do
|
||||
if (actorTableContent[i]) then
|
||||
actorTableContent[i]:RefreshLine (instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[i]:RefreshLine(instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
else
|
||||
for i = iter_last, instancia.barraS[1], -1 do
|
||||
if (actorTableContent[i]) then
|
||||
actorTableContent[i]:RefreshLine (instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[i]:RefreshLine(instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
end
|
||||
else
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
actorTableContent[myPos]:RefreshLine (instancia, lineContainer, whichRowLine, myPos, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[myPos]:RefreshLine(instancia, lineContainer, whichRowLine, myPos, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
for i = instancia.barraS[2]-1, instancia.barraS[1], -1 do
|
||||
if (actorTableContent[i]) then
|
||||
actorTableContent[i]:RefreshLine (instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[i]:RefreshLine(instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
@@ -2379,7 +2379,7 @@ function atributo_damage:RefreshWindow (instancia, combatObject, forcar, exporta
|
||||
-- /run print (Details:GetInstance(1).barraS[2]) -- vai do 5 ao 1 -- qual barra come�a no 1 -- i = 5 at� 1 -- player 5 atualiza na barra 1 / player 1 atualiza na barra 5
|
||||
for i = instancia.barraS[2], instancia.barraS[1], -1 do
|
||||
if (actorTableContent[i]) then
|
||||
actorTableContent[i]:RefreshLine (instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
actorTableContent[i]:RefreshLine(instancia, lineContainer, whichRowLine, i, total, subAttribute, forcar, keyName, combatTime, percentageType, useAnimations, barsShowData, barsBrackets, barsSeparator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
@@ -2578,7 +2578,7 @@ local actor_class_color_r, actor_class_color_g, actor_class_color_b
|
||||
end
|
||||
|
||||
-- ~atualizar ~barra ~update
|
||||
function atributo_damage:RefreshLine (instance, lineContainer, whichRowLine, rank, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
function atributo_damage:RefreshLine(instance, lineContainer, whichRowLine, rank, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
local thisLine = lineContainer[whichRowLine]
|
||||
|
||||
if (not thisLine) then
|
||||
@@ -3454,7 +3454,7 @@ function atributo_damage:ToolTip_DamageDone (instancia, numero, barra, keydown)
|
||||
|
||||
local allPlayers = {} --all players for this phase
|
||||
for playerName, amount in pairs(playersTable) do
|
||||
tinsert (allPlayers, {playerName, amount})
|
||||
tinsert(allPlayers, {playerName, amount})
|
||||
totalDamage = totalDamage + amount
|
||||
end
|
||||
table.sort (allPlayers, function(a, b) return a[2] > b[2] end)
|
||||
@@ -3467,7 +3467,7 @@ function atributo_damage:ToolTip_DamageDone (instancia, numero, barra, keydown)
|
||||
end
|
||||
end
|
||||
|
||||
tinsert (playerPhases, {phase, playersTable [self.nome] or 0, myRank, (playersTable [self.nome] or 0) / totalDamage * 100})
|
||||
tinsert(playerPhases, {phase, playersTable [self.nome] or 0, myRank, (playersTable [self.nome] or 0) / totalDamage * 100})
|
||||
end
|
||||
|
||||
table.sort (playerPhases, function(a, b) return a[1] < b[1] end)
|
||||
@@ -3486,12 +3486,12 @@ function atributo_damage:ToolTip_DamageDone (instancia, numero, barra, keydown)
|
||||
end
|
||||
|
||||
local on_switch_show_enemies = function(instance)
|
||||
instance:TrocaTabela (instance, true, 1, 6)
|
||||
instance:TrocaTabela(instance, true, 1, 6)
|
||||
return true
|
||||
end
|
||||
|
||||
local on_switch_show_frags = function(instance)
|
||||
instance:TrocaTabela (instance, true, 1, 5)
|
||||
instance:TrocaTabela(instance, true, 1, 5)
|
||||
return true
|
||||
end
|
||||
|
||||
@@ -3510,7 +3510,7 @@ function atributo_damage:ReportEnemyDamageTaken (actor, instance, ShiftKeyDown,
|
||||
if (not CustomObject.OnSwitchShow) then
|
||||
CustomObject.OnSwitchShow = fromFrags and on_switch_show_frags or on_switch_show_enemies
|
||||
end
|
||||
return instance:TrocaTabela (instance.segmento, 5, index)
|
||||
return instance:TrocaTabela(instance.segmento, 5, index)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -3529,11 +3529,11 @@ function atributo_damage:ReportEnemyDamageTaken (actor, instance, ShiftKeyDown,
|
||||
OnSwitchShow = fromFrags and on_switch_show_frags or on_switch_show_enemies,
|
||||
}
|
||||
|
||||
tinsert (Details.custom, new_custom_object)
|
||||
tinsert(Details.custom, new_custom_object)
|
||||
setmetatable (new_custom_object, Details.atributo_custom)
|
||||
new_custom_object.__index = Details.atributo_custom
|
||||
|
||||
return instance:TrocaTabela (instance.segmento, 5, #Details.custom)
|
||||
return instance:TrocaTabela(instance.segmento, 5, #Details.custom)
|
||||
end
|
||||
|
||||
local report_table = {"Details!: " .. actor.nome .. " - " .. Loc ["STRING_ATTRIBUTE_DAMAGE_TAKEN"]}
|
||||
@@ -3778,7 +3778,7 @@ function atributo_damage:ToolTip_DamageTaken (instancia, numero, barra, keydown)
|
||||
for spellid, spell in _pairs(aggressor.spells._ActorTable) do
|
||||
local on_target = spell.targets [self.nome]
|
||||
if (on_target) then
|
||||
tinsert (all_spells, {spellid, on_target, aggressor.nome})
|
||||
tinsert(all_spells, {spellid, on_target, aggressor.nome})
|
||||
end
|
||||
end
|
||||
|
||||
@@ -3786,7 +3786,7 @@ function atributo_damage:ToolTip_DamageTaken (instancia, numero, barra, keydown)
|
||||
local friendlyFire = aggressor.friendlyfire [self.nome]
|
||||
if (friendlyFire) then
|
||||
for spellid, amount in _pairs(friendlyFire.spells) do
|
||||
tinsert (all_spells, {spellid, amount, aggressor.nome})
|
||||
tinsert(all_spells, {spellid, amount, aggressor.nome})
|
||||
end
|
||||
end
|
||||
|
||||
@@ -4472,7 +4472,7 @@ function atributo_damage:MontaInfoDamageDone()
|
||||
if (barra.mouse_over) then --atualizar o tooltip
|
||||
if (barra.isAlvo) then
|
||||
GameTooltip:Hide()
|
||||
GameTooltip:SetOwner (barra, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:SetOwner(barra, "ANCHOR_TOPRIGHT")
|
||||
if (not barra.minha_tabela:MontaTooltipDamageTaken (barra, index)) then
|
||||
return
|
||||
end
|
||||
@@ -4548,7 +4548,7 @@ function atributo_damage:MontaInfoDamageDone()
|
||||
if (barra.mouse_over) then --atualizar o tooltip
|
||||
if (barra.isAlvo) then
|
||||
--GameTooltip:Hide()
|
||||
--GameTooltip:SetOwner (barra, "ANCHOR_TOPRIGHT")
|
||||
--GameTooltip:SetOwner(barra, "ANCHOR_TOPRIGHT")
|
||||
if (not barra.minha_tabela:MontaTooltipAlvos (barra, index, instancia)) then
|
||||
return
|
||||
end
|
||||
@@ -4646,10 +4646,10 @@ function atributo_damage:MontaDetalhesEnemy (spellid, barra)
|
||||
end
|
||||
|
||||
if (barra.lineText1:IsTruncated()) then
|
||||
Details:CooltipPreset (2)
|
||||
Details:CooltipPreset(2)
|
||||
GameCooltip:SetOption("FixedWidth", nil)
|
||||
GameCooltip:AddLine (barra.lineText1.text)
|
||||
GameCooltip:SetOwner (barra, "bottomleft", "topleft", 5, -10)
|
||||
GameCooltip:SetOwner(barra, "bottomleft", "topleft", 5, -10)
|
||||
GameCooltip:ShowCooltip()
|
||||
end
|
||||
|
||||
@@ -5066,7 +5066,7 @@ function Details:BuildPlayerDetailsSpellChart()
|
||||
for i = 1, 200 do
|
||||
local texture = playerDetailSmallChart:CreateTexture(nil, "artwork")
|
||||
texture:SetColorTexture (1, 1, 1, 1)
|
||||
tinsert (playerDetailSmallChart.Lines, texture)
|
||||
tinsert(playerDetailSmallChart.Lines, texture)
|
||||
end
|
||||
|
||||
--Details.playerDetailWindow.grupos_detalhes [index]
|
||||
|
||||
+21
-21
@@ -455,18 +455,18 @@ function atributo_heal:RefreshWindow (instancia, tabela_do_combate, forcar, expo
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
for i = instancia.barraS[1], iter_last-1, 1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
if (conteudo[i]) then
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
|
||||
conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[myPos]:RefreshLine(instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
else
|
||||
|
||||
for i = instancia.barraS[1], iter_last, 1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
if (conteudo[i]) then
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
@@ -476,17 +476,17 @@ function atributo_heal:RefreshWindow (instancia, tabela_do_combate, forcar, expo
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
for i = instancia.barraS[1], instancia.barraS[2]-1, 1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
if (conteudo[i]) then
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
|
||||
conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[myPos]:RefreshLine(instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
else
|
||||
for i = instancia.barraS[1], instancia.barraS[2], 1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
if (conteudo[i]) then
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
@@ -523,36 +523,36 @@ function atributo_heal:RefreshWindow (instancia, tabela_do_combate, forcar, expo
|
||||
Details.FadeHandler.Fader(row1, "out")
|
||||
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[myPos]:RefreshLine(instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
for i = iter_last-1, instancia.barraS[1], -1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
if (conteudo[i]) then
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
else
|
||||
for i = iter_last, instancia.barraS[1], -1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
if (conteudo[i]) then
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
end
|
||||
else
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[myPos]:RefreshLine(instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
for i = instancia.barraS[2]-1, instancia.barraS[1], -1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
if (conteudo[i]) then
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
else
|
||||
for i = instancia.barraS[2], instancia.barraS[1], -1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
if (conteudo[i]) then
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
@@ -594,7 +594,7 @@ end
|
||||
|
||||
local actor_class_color_r, actor_class_color_g, actor_class_color_b
|
||||
|
||||
--function atributo_heal:RefreshLine (instancia, whichRowLine, lugar, total, sub_atributo, forcar)
|
||||
--function atributo_heal:RefreshLine(instancia, whichRowLine, lugar, total, sub_atributo, forcar)
|
||||
function atributo_heal:RefreshLine(instancia, barras_container, whichRowLine, lugar, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
|
||||
local thisLine = instancia.barras[whichRowLine] --pega a refer�ncia da barra na janela
|
||||
@@ -1049,7 +1049,7 @@ function atributo_heal:ToolTip_HealingDenied (instancia, numero, barra, keydown)
|
||||
for spellID, spell in _pairs (self.spells._ActorTable) do
|
||||
if (spell.totaldenied > 0 and spell.heal_denied) then
|
||||
--my spells which denied heal
|
||||
tinsert (spellList, {spell, spell.totaldenied})
|
||||
tinsert(spellList, {spell, spell.totaldenied})
|
||||
|
||||
--players affected
|
||||
for playerName, amount in _pairs (spell.targets) do
|
||||
@@ -1108,7 +1108,7 @@ function atributo_heal:ToolTip_HealingDenied (instancia, numero, barra, keydown)
|
||||
--Target Players
|
||||
local playerSorted = {}
|
||||
for playerName, amount in _pairs (targetList) do
|
||||
tinsert (playerSorted, {playerName, amount})
|
||||
tinsert(playerSorted, {playerName, amount})
|
||||
end
|
||||
table.sort (playerSorted, _detalhes.Sort2)
|
||||
_detalhes:AddTooltipSpellHeaderText ("Targets", headerColor, #playerSorted, [[Interface\TUTORIALFRAME\UI-TutorialFrame-LevelUp]], 0.10546875, 0.89453125, 0.05859375, 0.6796875)
|
||||
@@ -1154,7 +1154,7 @@ function atributo_heal:ToolTip_HealingDenied (instancia, numero, barra, keydown)
|
||||
-- Spells Affected
|
||||
local spellsSorted = {}
|
||||
for spellID, amount in _pairs (spellsDenied) do
|
||||
tinsert (spellsSorted, {spellID, amount})
|
||||
tinsert(spellsSorted, {spellID, amount})
|
||||
end
|
||||
table.sort (spellsSorted, _detalhes.Sort2)
|
||||
_detalhes:AddTooltipSpellHeaderText ("Spells Affected", headerColor, #spellsSorted, [[Interface\TUTORIALFRAME\UI-TutorialFrame-LevelUp]], 0.10546875, 0.89453125, 0.05859375, 0.6796875)
|
||||
@@ -1191,7 +1191,7 @@ function atributo_heal:ToolTip_HealingDenied (instancia, numero, barra, keydown)
|
||||
|
||||
local healersSorted = {}
|
||||
for healerName, amount in _pairs (healersDenied) do
|
||||
tinsert (healersSorted, {healerName, amount})
|
||||
tinsert(healersSorted, {healerName, amount})
|
||||
end
|
||||
table.sort (healersSorted, _detalhes.Sort2)
|
||||
|
||||
@@ -1624,11 +1624,11 @@ function atributo_heal:ToolTip_HealingDone (instancia, numero, barra, keydown)
|
||||
local playerPhases = {}
|
||||
local totalDamage = 0
|
||||
|
||||
for phase, playersTable in pairs (phasesInfo.heal) do --each phase
|
||||
for phase, playersTable in pairs(phasesInfo.heal) do --each phase
|
||||
|
||||
local allPlayers = {} --all players for this phase
|
||||
for playerName, amount in pairs (playersTable) do
|
||||
tinsert (allPlayers, {playerName, amount})
|
||||
for playerName, amount in pairs(playersTable) do
|
||||
tinsert(allPlayers, {playerName, amount})
|
||||
totalDamage = totalDamage + amount
|
||||
end
|
||||
table.sort (allPlayers, function(a, b) return a[2] > b[2] end)
|
||||
@@ -1641,7 +1641,7 @@ function atributo_heal:ToolTip_HealingDone (instancia, numero, barra, keydown)
|
||||
end
|
||||
end
|
||||
|
||||
tinsert (playerPhases, {phase, playersTable [self.nome] or 0, myRank, (playersTable [self.nome] or 0) / totalDamage * 100})
|
||||
tinsert(playerPhases, {phase, playersTable [self.nome] or 0, myRank, (playersTable [self.nome] or 0) / totalDamage * 100})
|
||||
end
|
||||
|
||||
table.sort (playerPhases, function(a, b) return a[1] < b[1] end)
|
||||
|
||||
+43
-43
@@ -174,7 +174,7 @@ function _detalhes:GetMode()
|
||||
return self.modo
|
||||
end
|
||||
|
||||
function _detalhes:GetInstance (id)
|
||||
function _detalhes:GetInstance(id)
|
||||
return _detalhes.tabela_instancias [id]
|
||||
end
|
||||
--user friendly alias
|
||||
@@ -249,7 +249,7 @@ end
|
||||
|
||||
function _detalhes:ResetAttribute()
|
||||
if (self.iniciada) then
|
||||
self:TrocaTabela (nil, 1, 1, true)
|
||||
self:TrocaTabela(nil, 1, 1, true)
|
||||
else
|
||||
self.atributo = 1
|
||||
self.sub_atributo = 1
|
||||
@@ -501,7 +501,7 @@ end
|
||||
end
|
||||
|
||||
function _detalhes:ToggleWindow (index)
|
||||
local window = _detalhes:GetInstance (index)
|
||||
local window = _detalhes:GetInstance(index)
|
||||
|
||||
if (window and _getmetatable (window)) then
|
||||
if (window:IsEnabled()) then
|
||||
@@ -526,8 +526,8 @@ end
|
||||
end
|
||||
|
||||
function _detalhes:CheckCoupleWindows (instance1, instance2)
|
||||
instance1 = instance1 or _detalhes:GetInstance (1)
|
||||
instance2 = instance2 or _detalhes:GetInstance (2)
|
||||
instance1 = instance1 or _detalhes:GetInstance(1)
|
||||
instance2 = instance2 or _detalhes:GetInstance(2)
|
||||
|
||||
if (instance1 and instance2 and not instance1.ignore_mass_showhide and not instance1.ignore_mass_showhide) then
|
||||
|
||||
@@ -560,7 +560,7 @@ end
|
||||
local instance
|
||||
|
||||
for i = 1, #_detalhes.tabela_instancias do
|
||||
local this_instance = _detalhes:GetInstance (i)
|
||||
local this_instance = _detalhes:GetInstance(i)
|
||||
if (this_instance and not this_instance.ignore_mass_showhide) then
|
||||
instance = this_instance
|
||||
break
|
||||
@@ -590,7 +590,7 @@ end
|
||||
-- reabre todas as instancias
|
||||
function _detalhes:ReabrirTodasInstancias (temp)
|
||||
for index = math.min (#_detalhes.tabela_instancias, _detalhes.instances_amount), 1, -1 do
|
||||
local instancia = _detalhes:GetInstance (index)
|
||||
local instancia = _detalhes:GetInstance(index)
|
||||
if (instancia and not instancia.ignore_mass_showhide) then
|
||||
instancia:AtivarInstancia (temp, true)
|
||||
end
|
||||
@@ -670,7 +670,7 @@ end
|
||||
end
|
||||
|
||||
self:ChangeSkin() --carrega a skin aqui que era antes feito dentro do restaura janela
|
||||
_detalhes:TrocaTabela (self, nil, nil, nil, true)
|
||||
_detalhes:TrocaTabela(self, nil, nil, nil, true)
|
||||
|
||||
if (self.hide_icon) then
|
||||
Details.FadeHandler.Fader(self.baseframe.cabecalho.atributo_icon, 1)
|
||||
@@ -743,14 +743,14 @@ end
|
||||
|
||||
function _detalhes:DeleteInstance (id)
|
||||
|
||||
local instance = _detalhes:GetInstance (id)
|
||||
local instance = _detalhes:GetInstance(id)
|
||||
|
||||
if (not instance) then
|
||||
return false
|
||||
end
|
||||
|
||||
--break snaps of previous and next window
|
||||
local left_instance = _detalhes:GetInstance (id-1)
|
||||
local left_instance = _detalhes:GetInstance(id-1)
|
||||
if (left_instance) then
|
||||
for snap_side, instance_id in _pairs (left_instance.snap) do
|
||||
if (instance_id == id) then --snap na proxima instancia
|
||||
@@ -758,7 +758,7 @@ end
|
||||
end
|
||||
end
|
||||
end
|
||||
local right_instance = _detalhes:GetInstance (id+1)
|
||||
local right_instance = _detalhes:GetInstance(id+1)
|
||||
if (right_instance) then
|
||||
for snap_side, instance_id in _pairs (right_instance.snap) do
|
||||
if (instance_id == id) then --snap na proxima instancia
|
||||
@@ -769,7 +769,7 @@ end
|
||||
|
||||
--re align snaps for higher instances
|
||||
for i = id+1, #_detalhes.tabela_instancias do
|
||||
local this_instance = _detalhes:GetInstance (i)
|
||||
local this_instance = _detalhes:GetInstance(i)
|
||||
--fix the snaps
|
||||
for snap_side, instance_id in _pairs (this_instance.snap) do
|
||||
if (instance_id == i+1) then --snap na proxima instancia
|
||||
@@ -815,7 +815,7 @@ end
|
||||
local new_instance = _detalhes:NovaInstancia (next_id)
|
||||
|
||||
if (_detalhes.standard_skin) then
|
||||
for key, value in pairs (_detalhes.standard_skin) do
|
||||
for key, value in pairs(_detalhes.standard_skin) do
|
||||
if (type(value) == "table") then
|
||||
new_instance [key] = Details.CopyTable (value)
|
||||
else
|
||||
@@ -828,7 +828,7 @@ end
|
||||
--se n�o tiver um padr�o, criar de outra inst�ncia j� aberta.
|
||||
local copy_from
|
||||
for i = 1, next_id-1 do
|
||||
local opened_instance = _detalhes:GetInstance (i)
|
||||
local opened_instance = _detalhes:GetInstance(i)
|
||||
if (opened_instance and opened_instance:IsEnabled() and opened_instance.baseframe) then
|
||||
copy_from = opened_instance
|
||||
break
|
||||
@@ -836,7 +836,7 @@ end
|
||||
end
|
||||
|
||||
if (copy_from) then
|
||||
for key, value in pairs (copy_from) do
|
||||
for key, value in pairs(copy_from) do
|
||||
if (_detalhes.instance_defaults [key] ~= nil) then
|
||||
if (type(value) == "table") then
|
||||
new_instance [key] = Details.CopyTable (value)
|
||||
@@ -900,7 +900,7 @@ end
|
||||
------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
--self � a inst�ncia que esta sendo movida.. instancia � a que esta parada
|
||||
function _detalhes:EstaAgrupada (esta_instancia, lado) --lado //// 1 = encostou na esquerda // 2 = escostou emaixo // 3 = encostou na direita // 4 = encostou em cima
|
||||
function _detalhes:EstaAgrupada(esta_instancia, lado) --lado //// 1 = encostou na esquerda // 2 = escostou emaixo // 3 = encostou na direita // 4 = encostou em cima
|
||||
--local meu_snap = self.snap --pegou a tabela com {side, side, side, side}
|
||||
|
||||
if (esta_instancia.snap [lado]) then
|
||||
@@ -1069,7 +1069,7 @@ function _detalhes:BaseFrameSnap()
|
||||
end
|
||||
end
|
||||
|
||||
function _detalhes:agrupar_janelas (lados)
|
||||
function _detalhes:agrupar_janelas(lados)
|
||||
|
||||
local instancia = self
|
||||
|
||||
@@ -1162,7 +1162,7 @@ function _detalhes:agrupar_janelas (lados)
|
||||
|
||||
_detalhes.temp_table1.IconSize = 32
|
||||
_detalhes.temp_table1.TextHeightMod = -6
|
||||
_detalhes.popup:ShowMe (instancia.break_snap_button, "tooltip", "Interface\\Buttons\\LockButton-Unlocked-Up", Loc ["STRING_UNLOCK"], 150, _detalhes.temp_table1)
|
||||
_detalhes.popup:ShowMe(instancia.break_snap_button, "tooltip", "Interface\\Buttons\\LockButton-Unlocked-Up", Loc ["STRING_UNLOCK"], 150, _detalhes.temp_table1)
|
||||
|
||||
--UIFrameFlash (instancia.break_snap_button, .5, .5, 5, false, 0, 0)
|
||||
_detalhes.tutorial.unlock_button = _detalhes.tutorial.unlock_button + 1
|
||||
@@ -1448,7 +1448,7 @@ end
|
||||
new_instance.LastModo = modo_grupo
|
||||
|
||||
--change the attribute
|
||||
_detalhes:TrocaTabela (new_instance, 0, 1, 1)
|
||||
_detalhes:TrocaTabela(new_instance, 0, 1, 1)
|
||||
|
||||
--internal stuff
|
||||
new_instance.row_height = new_instance.row_info.height + new_instance.row_info.space.between
|
||||
@@ -1480,7 +1480,7 @@ end
|
||||
instance:ChangeSkin (skin)
|
||||
|
||||
--overwrite all instance parameters with saved ones
|
||||
for key, value in pairs (style) do
|
||||
for key, value in pairs(style) do
|
||||
if (key ~= "skin") then
|
||||
if (type(value) == "table") then
|
||||
instance [key] = Details.CopyTable (value)
|
||||
@@ -1546,13 +1546,13 @@ function _detalhes:RestauraJanela(index, temp, load_only)
|
||||
self.bgframe = _bgframe
|
||||
self.bgdisplay = _bgframe_display
|
||||
self.scroll = _scrollframe
|
||||
_baseframe:EnableMouseWheel (false)
|
||||
_baseframe:EnableMouseWheel(false)
|
||||
self.alturaAntiga = _baseframe:GetHeight()
|
||||
|
||||
--self.isLocked = isLocked --window isn't locked when just created it
|
||||
|
||||
--change the attribute
|
||||
_detalhes:TrocaTabela (self, self.segmento, self.atributo, self.sub_atributo, true) --passando true no 5� valor para a fun��o ignorar a checagem de valores iguais
|
||||
_detalhes:TrocaTabela(self, self.segmento, self.atributo, self.sub_atributo, true) --passando true no 5� valor para a fun��o ignorar a checagem de valores iguais
|
||||
|
||||
--set wallpaper
|
||||
if (self.wallpaper.enabled) then
|
||||
@@ -1656,7 +1656,7 @@ function _detalhes:SwitchBack()
|
||||
_detalhes.SoloTables:switch (nil, prev_switch [6])
|
||||
|
||||
else
|
||||
_detalhes:TrocaTabela (self, prev_switch [4], prev_switch [2], prev_switch [3])
|
||||
_detalhes:TrocaTabela(self, prev_switch [4], prev_switch [2], prev_switch [3])
|
||||
end
|
||||
|
||||
self.auto_switch_to_old = nil
|
||||
@@ -1692,7 +1692,7 @@ function _detalhes:SwitchTo (switch_table, nosave)
|
||||
if (self.modo ~= _detalhes._detalhes_props["MODO_GROUP"]) then
|
||||
_detalhes:AlteraModo (self, _detalhes._detalhes_props["MODO_GROUP"])
|
||||
end
|
||||
_detalhes:TrocaTabela (self, nil, switch_table [1], switch_table [2])
|
||||
_detalhes:TrocaTabela(self, nil, switch_table [1], switch_table [2])
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1729,7 +1729,7 @@ function _detalhes:CheckSwitchOnCombatEnd (nowipe, warning)
|
||||
local current_attribute, current_sub_atribute = self:GetDisplay()
|
||||
if (current_attribute ~= old_attribute or current_sub_atribute ~= old_sub_atribute) then
|
||||
local attribute_name = self:GetInstanceAttributeText()
|
||||
self:InstanceAlert (string.format (Loc ["STRING_SWITCH_WARNING"], attribute_name), {[[Interface\CHARACTERFRAME\UI-StateIcon]], 18, 18, false, 0.5, 1, 0, 0.5}, 4)
|
||||
self:InstanceAlert (string.format(Loc ["STRING_SWITCH_WARNING"], attribute_name), {[[Interface\CHARACTERFRAME\UI-StateIcon]], 18, 18, false, 0.5, 1, 0, 0.5}, 4)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1783,7 +1783,7 @@ function _detalhes:CheckSwitchOnCombatStart (check_segment)
|
||||
|
||||
if (check_segment and got_switch) then
|
||||
if (self:GetSegment() ~= 0) then
|
||||
self:TrocaTabela (0)
|
||||
self:TrocaTabela(0)
|
||||
end
|
||||
end
|
||||
|
||||
@@ -1813,7 +1813,7 @@ function _detalhes:ExportSkin()
|
||||
}
|
||||
|
||||
--export the keys
|
||||
for key, value in pairs (self) do
|
||||
for key, value in pairs(self) do
|
||||
if (_detalhes.instance_defaults [key] ~= nil) then
|
||||
if (type(value) == "table") then
|
||||
exported [key] = Details.CopyTable (value)
|
||||
@@ -1880,7 +1880,7 @@ function _detalhes:ApplySavedSkin (style)
|
||||
self:ChangeSkin (skin)
|
||||
|
||||
--overwrite all instance parameters with saved ones
|
||||
for key, value in pairs (style) do
|
||||
for key, value in pairs(style) do
|
||||
if (key ~= "skin") then
|
||||
if (type(value) == "table") then
|
||||
self [key] = Details.CopyTable (value)
|
||||
@@ -1891,9 +1891,9 @@ function _detalhes:ApplySavedSkin (style)
|
||||
end
|
||||
|
||||
--check for new keys inside tables
|
||||
for key, value in pairs (_detalhes.instance_defaults) do
|
||||
for key, value in pairs(_detalhes.instance_defaults) do
|
||||
if (type(value) == "table") then
|
||||
for key2, value2 in pairs (value) do
|
||||
for key2, value2 in pairs(value) do
|
||||
if (self [key] [key2] == nil) then
|
||||
if (type(value2) == "table") then
|
||||
self [key] [key2] = Details.CopyTable (_detalhes.instance_defaults [key] [key2])
|
||||
@@ -2198,7 +2198,7 @@ function _detalhes:SetDisplay(segment, attribute, subAttribute, isInstanceStarup
|
||||
return self:TrocaTabela(self, segment, attribute, subAttribute, isInstanceStarup, instanceMode)
|
||||
end
|
||||
|
||||
function _detalhes:TrocaTabela (instancia, segmento, atributo, sub_atributo, iniciando_instancia, InstanceMode)
|
||||
function _detalhes:TrocaTabela(instancia, segmento, atributo, sub_atributo, iniciando_instancia, InstanceMode)
|
||||
|
||||
if (self and self.meu_id and not instancia) then --self � uma inst�ncia
|
||||
InstanceMode = iniciando_instancia
|
||||
@@ -2324,7 +2324,7 @@ function _detalhes:TrocaTabela (instancia, segmento, atributo, sub_atributo, ini
|
||||
end
|
||||
|
||||
if (update_coolTip) then
|
||||
_detalhes.popup:Select (1, segmento+2)
|
||||
_detalhes.popup:Select(1, segmento+2)
|
||||
end
|
||||
|
||||
if (instancia.showing and instancia.showing.contra) then
|
||||
@@ -2393,10 +2393,10 @@ function _detalhes:TrocaTabela (instancia, segmento, atributo, sub_atributo, ini
|
||||
|
||||
if (instancia.modo == modo_alone and not (_detalhes.initializing or iniciando_instancia)) then
|
||||
if (_detalhes.SoloTables.Mode == #_detalhes.SoloTables.Plugins) then
|
||||
_detalhes.popup:Select (1, 1)
|
||||
_detalhes.popup:Select(1, 1)
|
||||
else
|
||||
if (_detalhes.PluginCount.SOLO > 0) then
|
||||
_detalhes.popup:Select (1, _detalhes.SoloTables.Mode+1)
|
||||
_detalhes.popup:Select(1, _detalhes.SoloTables.Mode+1)
|
||||
end
|
||||
end
|
||||
return _detalhes.SoloTables.switch (nil, nil, -1)
|
||||
@@ -2413,8 +2413,8 @@ function _detalhes:TrocaTabela (instancia, segmento, atributo, sub_atributo, ini
|
||||
instancia:ChangeIcon()
|
||||
|
||||
if (update_coolTip) then
|
||||
_detalhes.popup:Select (1, atributo)
|
||||
_detalhes.popup:Select (2, instancia.sub_atributo, atributo)
|
||||
_detalhes.popup:Select(1, atributo)
|
||||
_detalhes.popup:Select(2, instancia.sub_atributo, atributo)
|
||||
end
|
||||
|
||||
if (_detalhes.cloud_process) then
|
||||
@@ -2948,10 +2948,10 @@ function _detalhes:AlteraModo (instancia, qual, from_mode_menu)
|
||||
checked = 3
|
||||
end
|
||||
|
||||
_detalhes.popup:Select (1, checked)
|
||||
_detalhes.popup:Select(1, checked)
|
||||
|
||||
if (from_mode_menu) then
|
||||
instancia.baseframe.cabecalho.modo_selecao:GetScript ("OnEnter")(instancia.baseframe.cabecalho.modo_selecao, _, true)
|
||||
instancia.baseframe.cabecalho.modo_selecao:GetScript("OnEnter")(instancia.baseframe.cabecalho.modo_selecao, _, true)
|
||||
|
||||
--running OnEnter does also trigger an instance enter event, so we need to manually leave the instance:
|
||||
_detalhes.OnLeaveMainWindow(instancia, instancia.baseframe.cabecalho.modo_selecao)
|
||||
@@ -3140,13 +3140,13 @@ function _detalhes:monta_relatorio (este_relatorio, custom)
|
||||
--push it to front
|
||||
local t = tremove (_detalhes.latest_report_table, already_exists)
|
||||
t [4] = amt
|
||||
tinsert (_detalhes.latest_report_table, 1, t)
|
||||
tinsert(_detalhes.latest_report_table, 1, t)
|
||||
else
|
||||
if (self.atributo == 5) then
|
||||
local custom_name = self:GetCustomObject():GetName()
|
||||
tinsert (_detalhes.latest_report_table, 1, {self.meu_id, self.atributo, self.sub_atributo, amt, _detalhes.report_where, custom_name})
|
||||
tinsert(_detalhes.latest_report_table, 1, {self.meu_id, self.atributo, self.sub_atributo, amt, _detalhes.report_where, custom_name})
|
||||
else
|
||||
tinsert (_detalhes.latest_report_table, 1, {self.meu_id, self.atributo, self.sub_atributo, amt, _detalhes.report_where})
|
||||
tinsert(_detalhes.latest_report_table, 1, {self.meu_id, self.atributo, self.sub_atributo, amt, _detalhes.report_where})
|
||||
end
|
||||
end
|
||||
|
||||
@@ -3170,7 +3170,7 @@ function _detalhes:monta_relatorio (este_relatorio, custom)
|
||||
if (self.sub_atributo == 5) then --frags
|
||||
local frags = self.showing.frags
|
||||
local reportarFrags = {}
|
||||
for name, amount in pairs (frags) do
|
||||
for name, amount in pairs(frags) do
|
||||
--string para imprimir direto sem calculos
|
||||
reportarFrags [#reportarFrags+1] = {frag = tostring (amount), nome = name}
|
||||
end
|
||||
@@ -3284,7 +3284,7 @@ function _detalhes:monta_relatorio (este_relatorio, custom)
|
||||
if (is_reverse) then
|
||||
local t = {}
|
||||
for i = #raw_data_to_report, 1, -1 do
|
||||
tinsert (t, raw_data_to_report [i])
|
||||
tinsert(t, raw_data_to_report [i])
|
||||
if (#t >= amt) then
|
||||
break
|
||||
end
|
||||
|
||||
+15
-15
@@ -542,15 +542,15 @@ function atributo_energy:RefreshWindow (instancia, tabela_do_combate, forcar, ex
|
||||
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
for i = instancia.barraS[1], iter_last-1, 1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
|
||||
conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[myPos]:RefreshLine(instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
else
|
||||
for i = instancia.barraS[1], iter_last, 1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
@@ -558,15 +558,15 @@ function atributo_energy:RefreshWindow (instancia, tabela_do_combate, forcar, ex
|
||||
else
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
for i = instancia.barraS[1], instancia.barraS[2]-1, 1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
|
||||
conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[myPos]:RefreshLine(instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
else
|
||||
for i = instancia.barraS[1], instancia.barraS[2], 1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
@@ -602,29 +602,29 @@ function atributo_energy:RefreshWindow (instancia, tabela_do_combate, forcar, ex
|
||||
Details.FadeHandler.Fader(row1, "out")
|
||||
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[myPos]:RefreshLine(instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
for i = iter_last-1, instancia.barraS[1], -1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
else
|
||||
for i = iter_last, instancia.barraS[1], -1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
else
|
||||
if (following and myPos and myPos > instancia.rows_fit_in_window and instancia.barraS[2] < myPos) then
|
||||
conteudo[myPos]:RefreshLine (instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[myPos]:RefreshLine(instancia, barras_container, whichRowLine, myPos, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
for i = instancia.barraS[2]-1, instancia.barraS[1], -1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
else
|
||||
for i = instancia.barraS[2], instancia.barraS[1], -1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator) --inst�ncia, index, total, valor da 1� barra
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
@@ -648,7 +648,7 @@ function atributo_energy:RefreshWindow (instancia, tabela_do_combate, forcar, ex
|
||||
|
||||
end
|
||||
|
||||
function atributo_energy:RefreshLine (instancia, barras_container, whichRowLine, lugar, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
function atributo_energy:RefreshLine(instancia, barras_container, whichRowLine, lugar, total, sub_atributo, forcar, keyName, combat_time, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
|
||||
local esta_barra = instancia.barras[whichRowLine] --pega a refer�ncia da barra na janela
|
||||
|
||||
@@ -1002,7 +1002,7 @@ function atributo_energy:ToolTipRegenRecebido (instancia, numero, barra, keydown
|
||||
local allGeneratorSpells = {}
|
||||
local allGenerated = 0
|
||||
for spellid, spellObject in _pairs (self.spells._ActorTable) do
|
||||
tinsert (allGeneratorSpells, {spellObject, spellObject.total, spellObject.totalover})
|
||||
tinsert(allGeneratorSpells, {spellObject, spellObject.total, spellObject.totalover})
|
||||
allGenerated = allGenerated + spellObject.total
|
||||
end
|
||||
|
||||
@@ -1193,7 +1193,7 @@ function atributo_energy:MontaInfoRegenRecebido()
|
||||
if (barra.mouse_over) then --atualizar o tooltip
|
||||
if (barra.isAlvo) then
|
||||
GameTooltip:Hide()
|
||||
GameTooltip:SetOwner (barra, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:SetOwner(barra, "ANCHOR_TOPRIGHT")
|
||||
if (not barra.minha_tabela:MontaTooltipAlvos (barra, index)) then
|
||||
return
|
||||
end
|
||||
|
||||
+119
-119
@@ -160,7 +160,7 @@ end
|
||||
--try to find a spell with the same name and get the amount of casts of that spell object
|
||||
if (not spell_cast and misc_actor.spell_cast) then
|
||||
local spellname = GetSpellInfo(spellId)
|
||||
for casted_spellid, amount in pairs (misc_actor.spell_cast) do
|
||||
for casted_spellid, amount in pairs(misc_actor.spell_cast) do
|
||||
local casted_spellname = GetSpellInfo(casted_spellid)
|
||||
if (casted_spellname == spellname) then
|
||||
return amount, true
|
||||
@@ -391,7 +391,7 @@ local ReportSingleDeathFunc = function(IsCurrent, IsReverse, AmtLines)
|
||||
|
||||
local title = tremove (t, 1)
|
||||
t = _detalhes.table.reverse (t)
|
||||
tinsert (t, 1, title)
|
||||
tinsert(t, 1, title)
|
||||
|
||||
_detalhes:SendReportLines (t)
|
||||
|
||||
@@ -444,7 +444,7 @@ function atributo_misc:ReportSingleDeadLine (morte, instancia)
|
||||
hp = 100
|
||||
end
|
||||
|
||||
tinsert (report_array, {elapsed .. " ", spelllink, " (" .. source .. ")", "-" .. _detalhes:ToK (amount) .. " (" .. hp .. "%) "})
|
||||
tinsert(report_array, {elapsed .. " ", spelllink, " (" .. source .. ")", "-" .. _detalhes:ToK (amount) .. " (" .. hp .. "%) "})
|
||||
end
|
||||
|
||||
elseif (not evento [1] and type (evento [1]) == "boolean") then --heal
|
||||
@@ -463,9 +463,9 @@ function atributo_misc:ReportSingleDeadLine (morte, instancia)
|
||||
end
|
||||
|
||||
if (_detalhes.report_heal_links) then
|
||||
tinsert (report_array, {elapsed .. " ", spelllink, " (" .. source .. ")", "+" .. _detalhes:ToK (amount) .. " (" .. hp .. "%) "})
|
||||
tinsert(report_array, {elapsed .. " ", spelllink, " (" .. source .. ")", "+" .. _detalhes:ToK (amount) .. " (" .. hp .. "%) "})
|
||||
else
|
||||
tinsert (report_array, {elapsed .. " ", spellname, " (" .. source .. ")", "+" .. _detalhes:ToK (amount) .. " (" .. hp .. "%) "})
|
||||
tinsert(report_array, {elapsed .. " ", spellname, " (" .. source .. ")", "+" .. _detalhes:ToK (amount) .. " (" .. hp .. "%) "})
|
||||
end
|
||||
end
|
||||
|
||||
@@ -481,7 +481,7 @@ function atributo_misc:ReportSingleDeadLine (morte, instancia)
|
||||
hp = 100
|
||||
end
|
||||
|
||||
tinsert (report_array, {elapsed .. " ", "x" .. stacks .. "" .. spelllink, " (" .. source .. ")", "(" .. hp .. "%) "})
|
||||
tinsert(report_array, {elapsed .. " ", "x" .. stacks .. "" .. spelllink, " (" .. source .. ")", "(" .. hp .. "%) "})
|
||||
end
|
||||
end
|
||||
|
||||
@@ -502,7 +502,7 @@ function atributo_misc:ReportSingleCooldownLine (misc_actor, instancia)
|
||||
local cooldowns = misc_actor.cooldowns_defensive_spells._ActorTable
|
||||
local cooldowns_used = {}
|
||||
|
||||
for spellid, spell in pairs (cooldowns) do
|
||||
for spellid, spell in pairs(cooldowns) do
|
||||
cooldowns_used [#cooldowns_used+1] = {spellid, spell.counter, spell}
|
||||
end
|
||||
table.sort (cooldowns_used, _detalhes.Sort2)
|
||||
@@ -512,7 +512,7 @@ function atributo_misc:ReportSingleCooldownLine (misc_actor, instancia)
|
||||
local spelllink = GetSpellLink(spell [1])
|
||||
reportar [#reportar+1] = spelllink .. ": " .. spell [2]
|
||||
|
||||
for target_name, amount in pairs (spell[3].targets) do
|
||||
for target_name, amount in pairs(spell[3].targets) do
|
||||
if (target_name ~= misc_actor.nome and target_name ~= Loc ["STRING_RAID_WIDE"] and amount > 0) then
|
||||
reportar [#reportar+1] = " -" .. target_name .. ": " .. amount
|
||||
end
|
||||
@@ -544,7 +544,7 @@ function atributo_misc:ReportSingleBuffUptimeLine (misc_actor, instance)
|
||||
local buffs = {}
|
||||
local combat_time = instance.showing:GetCombatTime()
|
||||
|
||||
for spellid, spell in pairs (misc_actor.buff_uptime_spells._ActorTable) do
|
||||
for spellid, spell in pairs(misc_actor.buff_uptime_spells._ActorTable) do
|
||||
local percent = spell.uptime / combat_time * 100
|
||||
if (percent < 99.5) then
|
||||
buffs [#buffs+1] = {spellid, {spell.uptime, percent}}
|
||||
@@ -562,7 +562,7 @@ function atributo_misc:ReportSingleDebuffUptimeLine (misc_actor, instance)
|
||||
local debuffs = {}
|
||||
local combat_time = instance.showing:GetCombatTime()
|
||||
|
||||
for spellid, spell in pairs (misc_actor.debuff_uptime_spells._ActorTable) do
|
||||
for spellid, spell in pairs(misc_actor.debuff_uptime_spells._ActorTable) do
|
||||
local percent = spell.uptime / combat_time * 100
|
||||
debuffs [#debuffs+1] = {spellid, {spell.uptime, percent}}
|
||||
end
|
||||
@@ -842,14 +842,14 @@ function atributo_misc:RefreshWindow (instancia, tabela_do_combate, forcar, expo
|
||||
|
||||
if (instancia.bars_sort_direction == 1) then --top to bottom
|
||||
for i = instancia.barraS[1], instancia.barraS[2], 1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, nil, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, nil, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
|
||||
elseif (instancia.bars_sort_direction == 2) then --bottom to top
|
||||
for i = instancia.barraS[2], instancia.barraS[1], -1 do --vai atualizar s� o range que esta sendo mostrado
|
||||
if (conteudo[i]) then
|
||||
conteudo[i]:RefreshLine (instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, nil, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
conteudo[i]:RefreshLine(instancia, barras_container, whichRowLine, i, total, sub_atributo, forcar, keyName, nil, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
whichRowLine = whichRowLine+1
|
||||
end
|
||||
end
|
||||
@@ -886,7 +886,7 @@ end
|
||||
|
||||
local actor_class_color_r, actor_class_color_g, actor_class_color_b
|
||||
|
||||
function atributo_misc:RefreshLine (instancia, barras_container, whichRowLine, lugar, total, sub_atributo, forcar, keyName, is_dead, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
function atributo_misc:RefreshLine(instancia, barras_container, whichRowLine, lugar, total, sub_atributo, forcar, keyName, is_dead, percentage_type, use_animations, bars_show_data, bars_brackets, bars_separator)
|
||||
|
||||
local esta_barra = instancia.barras[whichRowLine] --pega a refer�ncia da barra na janela
|
||||
|
||||
@@ -1093,7 +1093,7 @@ function atributo_misc:ToolTipCC (instancia, numero, barra)
|
||||
local lineHeight = _detalhes.tooltip.line_height
|
||||
local icon_border = _detalhes.tooltip.icon_border_texcoord
|
||||
|
||||
for _spellid, _tabela in pairs (habilidades) do
|
||||
for _spellid, _tabela in pairs(habilidades) do
|
||||
|
||||
--quantidade
|
||||
local nome_magia, _, icone_magia = _GetSpellInfo(_spellid)
|
||||
@@ -1103,7 +1103,7 @@ function atributo_misc:ToolTipCC (instancia, numero, barra)
|
||||
|
||||
--o que quebrou
|
||||
local quebrou_oque = _tabela.cc_break_oque
|
||||
for spellid_quebrada, amt_quebrada in pairs (_tabela.cc_break_oque) do
|
||||
for spellid_quebrada, amt_quebrada in pairs(_tabela.cc_break_oque) do
|
||||
local nome_magia, _, icone_magia = _GetSpellInfo(spellid_quebrada)
|
||||
GameCooltip:AddLine (nome_magia, amt_quebrada .. " ")
|
||||
GameCooltip:AddIcon ([[Interface\Buttons\UI-GroupLoot-Pass-Down]], nil, 1, 14, 14)
|
||||
@@ -1112,7 +1112,7 @@ function atributo_misc:ToolTipCC (instancia, numero, barra)
|
||||
end
|
||||
|
||||
--em quem quebrou
|
||||
for target_name, amount in pairs (_tabela.targets) do
|
||||
for target_name, amount in pairs(_tabela.targets) do
|
||||
GameCooltip:AddLine (target_name .. ": ", amount .. " ")
|
||||
|
||||
local classe = _detalhes:GetClass (target_name)
|
||||
@@ -1145,7 +1145,7 @@ function atributo_misc:ToolTipDispell (instancia, numero, barra)
|
||||
|
||||
--habilidade usada para dispelar
|
||||
local meus_dispells = {}
|
||||
for _spellid, _tabela in pairs (habilidades) do
|
||||
for _spellid, _tabela in pairs(habilidades) do
|
||||
if (_tabela.dispell) then
|
||||
meus_dispells [#meus_dispells+1] = {_spellid, _math_floor(_tabela.dispell)} --_math_floor valor é nil, uma magia na tabela de dispel, sem dispel?
|
||||
else
|
||||
@@ -1174,7 +1174,7 @@ function atributo_misc:ToolTipDispell (instancia, numero, barra)
|
||||
|
||||
--quais habilidades foram dispaladas
|
||||
local buffs_dispelados = {}
|
||||
for _spellid, amt in pairs (self.dispell_oque) do
|
||||
for _spellid, amt in pairs(self.dispell_oque) do
|
||||
buffs_dispelados [#buffs_dispelados+1] = {_spellid, amt}
|
||||
end
|
||||
table.sort (buffs_dispelados, _detalhes.Sort2)
|
||||
@@ -1195,7 +1195,7 @@ function atributo_misc:ToolTipDispell (instancia, numero, barra)
|
||||
--alvos dispelados
|
||||
|
||||
local alvos_dispelados = {}
|
||||
for target_name, amount in pairs (self.dispell_targets) do
|
||||
for target_name, amount in pairs(self.dispell_targets) do
|
||||
alvos_dispelados [#alvos_dispelados + 1] = {target_name, _math_floor(amount), amount / meu_total * 100}
|
||||
end
|
||||
table.sort (alvos_dispelados, _detalhes.Sort2)
|
||||
@@ -1312,7 +1312,7 @@ function _detalhes:CatchRaidDebuffUptime (in_or_out) -- "DEBUFF_UPTIME_IN"
|
||||
|
||||
for _, actor in ipairs(misc_container) do
|
||||
if (actor.debuff_uptime) then
|
||||
for spellid, spell in pairs (actor.debuff_uptime_spells._ActorTable) do
|
||||
for spellid, spell in pairs(actor.debuff_uptime_spells._ActorTable) do
|
||||
if (spell.actived and spell.actived_at) then
|
||||
spell.uptime = spell.uptime + _detalhes._tempo - spell.actived_at
|
||||
actor.debuff_uptime = actor.debuff_uptime + _detalhes._tempo - spell.actived_at
|
||||
@@ -1481,7 +1481,7 @@ function _detalhes:CatchRaidBuffUptime (in_or_out)
|
||||
if (in_or_out == "BUFF_UPTIME_IN") then
|
||||
local string_output = "pre-potion: " --localize-me
|
||||
|
||||
for playername, potspellid in pairs (pot_usage) do
|
||||
for playername, potspellid in pairs(pot_usage) do
|
||||
local name, _, icon = _GetSpellInfo(potspellid)
|
||||
local _, class = UnitClass (playername)
|
||||
local class_color = ""
|
||||
@@ -1553,7 +1553,7 @@ function _detalhes:CatchRaidBuffUptime (in_or_out)
|
||||
if (in_or_out == "BUFF_UPTIME_IN") then
|
||||
local string_output = "pre-potion: "
|
||||
|
||||
for playername, potspellid in pairs (pot_usage) do
|
||||
for playername, potspellid in pairs(pot_usage) do
|
||||
local name, _, icon = _GetSpellInfo(potspellid)
|
||||
local _, class = UnitClass (playername)
|
||||
local class_color = ""
|
||||
@@ -1594,7 +1594,7 @@ function _detalhes:CatchRaidBuffUptime (in_or_out)
|
||||
--[
|
||||
if (in_or_out == "BUFF_UPTIME_IN") then
|
||||
local string_output = "pre-potion: "
|
||||
for playername, potspellid in pairs (pot_usage) do
|
||||
for playername, potspellid in pairs(pot_usage) do
|
||||
local name, _, icon = _GetSpellInfo(potspellid)
|
||||
local _, class = UnitClass (playername)
|
||||
local class_color = ""
|
||||
@@ -1635,7 +1635,7 @@ function atributo_misc:ToolTipDebuffUptime (instancia, numero, barra)
|
||||
|
||||
local _combat_time = instancia.showing:GetCombatTime()
|
||||
|
||||
for _spellid, _tabela in pairs (minha_tabela) do
|
||||
for _spellid, _tabela in pairs(minha_tabela) do
|
||||
debuffs_usados [#debuffs_usados+1] = {_spellid, _tabela.uptime}
|
||||
end
|
||||
table.sort (debuffs_usados, _detalhes.Sort2)
|
||||
@@ -1747,7 +1747,7 @@ function atributo_misc:ToolTipDefensiveCooldowns (instancia, numero, barra)
|
||||
--spells
|
||||
local cooldowns_usados = {}
|
||||
|
||||
for _spellid, _tabela in pairs (minha_tabela) do
|
||||
for _spellid, _tabela in pairs(minha_tabela) do
|
||||
cooldowns_usados [#cooldowns_usados+1] = {_spellid, _tabela.counter}
|
||||
end
|
||||
table.sort (cooldowns_usados, _detalhes.Sort2)
|
||||
@@ -1775,7 +1775,7 @@ function atributo_misc:ToolTipDefensiveCooldowns (instancia, numero, barra)
|
||||
local meus_alvos = self.cooldowns_defensive_targets
|
||||
local alvos = {}
|
||||
|
||||
for target_name, amount in pairs (meus_alvos) do
|
||||
for target_name, amount in pairs(meus_alvos) do
|
||||
alvos [#alvos+1] = {target_name, amount}
|
||||
end
|
||||
table.sort (alvos, _detalhes.Sort2)
|
||||
@@ -1833,7 +1833,7 @@ function atributo_misc:ToolTipRess (instancia, numero, barra)
|
||||
--habilidade usada para interromper
|
||||
local meus_ress = {}
|
||||
|
||||
for _spellid, _tabela in pairs (minha_tabela) do
|
||||
for _spellid, _tabela in pairs(minha_tabela) do
|
||||
meus_ress [#meus_ress+1] = {_spellid, _tabela.ress}
|
||||
end
|
||||
table.sort (meus_ress, _detalhes.Sort2)
|
||||
@@ -1857,7 +1857,7 @@ function atributo_misc:ToolTipRess (instancia, numero, barra)
|
||||
local meus_alvos = self.ress_targets
|
||||
local alvos = {}
|
||||
|
||||
for target_name, amount in pairs (meus_alvos) do
|
||||
for target_name, amount in pairs(meus_alvos) do
|
||||
alvos [#alvos+1] = {target_name, amount}
|
||||
end
|
||||
table.sort (alvos, _detalhes.Sort2)
|
||||
@@ -1915,7 +1915,7 @@ function atributo_misc:ToolTipInterrupt (instancia, numero, barra)
|
||||
--habilidade usada para interromper
|
||||
local meus_interrupts = {}
|
||||
|
||||
for _spellid, _tabela in pairs (minha_tabela) do
|
||||
for _spellid, _tabela in pairs(minha_tabela) do
|
||||
meus_interrupts [#meus_interrupts+1] = {_spellid, _tabela.counter}
|
||||
end
|
||||
table.sort (meus_interrupts, _detalhes.Sort2)
|
||||
@@ -1938,7 +1938,7 @@ function atributo_misc:ToolTipInterrupt (instancia, numero, barra)
|
||||
--quais habilidades foram interrompidas
|
||||
local habilidades_interrompidas = {}
|
||||
|
||||
for _spellid, amt in pairs (self.interrompeu_oque) do
|
||||
for _spellid, amt in pairs(self.interrompeu_oque) do
|
||||
habilidades_interrompidas [#habilidades_interrompidas+1] = {_spellid, amt}
|
||||
end
|
||||
table.sort (habilidades_interrompidas, _detalhes.Sort2)
|
||||
@@ -2046,7 +2046,7 @@ function atributo_misc:MontaInfoInterrupt()
|
||||
local meus_interrupts = {}
|
||||
|
||||
--player
|
||||
for _spellid, _tabela in pairs (minha_tabela) do --da foreach em cada spellid do container
|
||||
for _spellid, _tabela in pairs(minha_tabela) do --da foreach em cada spellid do container
|
||||
local nome, _, icone = _GetSpellInfo(_spellid)
|
||||
_table_insert (meus_interrupts, {_spellid, _tabela.counter, _tabela.counter/meu_total*100, nome, icone})
|
||||
end
|
||||
@@ -2057,7 +2057,7 @@ function atributo_misc:MontaInfoInterrupt()
|
||||
local PetActor = instancia.showing (class_type, PetName)
|
||||
if (PetActor and PetActor.interrupt and PetActor.interrupt > 0) then
|
||||
local PetSkillsContainer = PetActor.interrupt_spells._ActorTable
|
||||
for _spellid, _skill in pairs (PetSkillsContainer) do --da foreach em cada spellid do container
|
||||
for _spellid, _skill in pairs(PetSkillsContainer) do --da foreach em cada spellid do container
|
||||
local nome, _, icone = _GetSpellInfo(_spellid)
|
||||
_table_insert (meus_interrupts, {_spellid, _skill.counter, _skill.counter/meu_total*100, nome .. " (|c" .. class_color .. PetName:gsub ((" <.*"), "") .. "|r)", icone, PetActor})
|
||||
end
|
||||
@@ -2125,7 +2125,7 @@ function atributo_misc:MontaInfoInterrupt()
|
||||
|
||||
--Alvos do interrupt
|
||||
local meus_alvos = {}
|
||||
for target_name, amount in pairs (self.interrupt_targets) do
|
||||
for target_name, amount in pairs(self.interrupt_targets) do
|
||||
meus_alvos [#meus_alvos+1] = {target_name, amount}
|
||||
end
|
||||
table.sort (meus_alvos, _detalhes.Sort2)
|
||||
@@ -2160,7 +2160,7 @@ function atributo_misc:MontaInfoInterrupt()
|
||||
if (barra.mouse_over) then --atualizar o tooltip
|
||||
if (barra.isAlvo) then
|
||||
GameTooltip:Hide()
|
||||
GameTooltip:SetOwner (barra, "ANCHOR_TOPRIGHT")
|
||||
GameTooltip:SetOwner(barra, "ANCHOR_TOPRIGHT")
|
||||
if (not barra.minha_tabela:MontaTooltipAlvos (barra, index)) then
|
||||
return
|
||||
end
|
||||
@@ -2206,7 +2206,7 @@ function atributo_misc:MontaDetalhesInterrupt (spellid, barra)
|
||||
local instancia = info.instancia
|
||||
|
||||
local habilidades_alvos = {}
|
||||
for spellid, amt in pairs (esta_magia.interrompeu_oque) do
|
||||
for spellid, amt in pairs(esta_magia.interrompeu_oque) do
|
||||
habilidades_alvos [#habilidades_alvos+1] = {spellid, amt}
|
||||
end
|
||||
table.sort (habilidades_alvos, _detalhes.Sort2)
|
||||
@@ -2256,7 +2256,7 @@ function atributo_misc:MontaTooltipAlvos (esta_barra, index)
|
||||
local habilidades = {}
|
||||
local total = self.interrupt
|
||||
|
||||
for spellid, tabela in pairs (container) do
|
||||
for spellid, tabela in pairs(container) do
|
||||
--tabela = classe_damage_habilidade
|
||||
local alvos = tabela.targets
|
||||
for target_name, amount in ipairs(alvos) do
|
||||
@@ -2328,12 +2328,12 @@ end
|
||||
end
|
||||
|
||||
local refresh_alvos = function(container1, container2)
|
||||
for target_name, amount in pairs (container2) do
|
||||
for target_name, amount in pairs(container2) do
|
||||
container1 [target_name] = container1 [target_name] or 0
|
||||
end
|
||||
end
|
||||
local refresh_habilidades = function(container1, container2)
|
||||
for spellid, habilidade in pairs (container2._ActorTable) do
|
||||
for spellid, habilidade in pairs(container2._ActorTable) do
|
||||
local habilidade_shadow = container1:PegaHabilidade (spellid, true, nil, true)
|
||||
refresh_alvos (habilidade_shadow.targets , habilidade.targets)
|
||||
end
|
||||
@@ -2369,7 +2369,7 @@ function atributo_misc:r_onlyrefresh_shadow (actor)
|
||||
if (not shadow.spell_cast) then
|
||||
shadow.spell_cast = {}
|
||||
end
|
||||
for spellid, _ in pairs (actor.spell_cast) do
|
||||
for spellid, _ in pairs(actor.spell_cast) do
|
||||
shadow.spell_cast [spellid] = shadow.spell_cast [spellid] or 0
|
||||
end
|
||||
end
|
||||
@@ -2407,7 +2407,7 @@ function atributo_misc:r_onlyrefresh_shadow (actor)
|
||||
if (actor.interrupt) then
|
||||
refresh_alvos (shadow.interrupt_targets, actor.interrupt_targets)
|
||||
refresh_habilidades (shadow.interrupt_spells, actor.interrupt_spells)
|
||||
for spellid, habilidade in pairs (actor.interrupt_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(actor.interrupt_spells._ActorTable) do
|
||||
local habilidade_shadow = shadow.interrupt_spells:PegaHabilidade (spellid, true, nil, true)
|
||||
habilidade_shadow.interrompeu_oque = habilidade_shadow.interrompeu_oque or {}
|
||||
end
|
||||
@@ -2423,7 +2423,7 @@ function atributo_misc:r_onlyrefresh_shadow (actor)
|
||||
if (actor.dispell) then
|
||||
refresh_alvos (shadow.dispell_targets, actor.dispell_targets)
|
||||
refresh_habilidades (shadow.dispell_spells, actor.dispell_spells)
|
||||
for spellid, habilidade in pairs (actor.dispell_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(actor.dispell_spells._ActorTable) do
|
||||
local habilidade_shadow = shadow.dispell_spells:PegaHabilidade (spellid, true, nil, true)
|
||||
habilidade_shadow.dispell_oque = habilidade_shadow.dispell_oque or {}
|
||||
end
|
||||
@@ -2433,7 +2433,7 @@ function atributo_misc:r_onlyrefresh_shadow (actor)
|
||||
if (actor.cc_break) then
|
||||
refresh_alvos (shadow.cc_break_targets, actor.cc_break_targets)
|
||||
refresh_habilidades (shadow.cc_break_spells, actor.cc_break_spells)
|
||||
for spellid, habilidade in pairs (actor.cc_break_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(actor.cc_break_spells._ActorTable) do
|
||||
local habilidade_shadow = shadow.cc_break_spells:PegaHabilidade (spellid, true, nil, true)
|
||||
habilidade_shadow.cc_break_oque = habilidade_shadow.cc_break_oque or {}
|
||||
end
|
||||
@@ -2444,7 +2444,7 @@ function atributo_misc:r_onlyrefresh_shadow (actor)
|
||||
end
|
||||
|
||||
local somar_keys = function(habilidade, habilidade_tabela1)
|
||||
for key, value in pairs (habilidade) do
|
||||
for key, value in pairs(habilidade) do
|
||||
if (_type(value) == "number") then
|
||||
if (key ~= "id" and key ~= "spellschool") then
|
||||
habilidade_tabela1 [key] = (habilidade_tabela1 [key] or 0) + value
|
||||
@@ -2453,12 +2453,12 @@ local somar_keys = function(habilidade, habilidade_tabela1)
|
||||
end
|
||||
end
|
||||
local somar_alvos = function(container1, container2)
|
||||
for target_name, amount in pairs (container2) do
|
||||
for target_name, amount in pairs(container2) do
|
||||
container1 [target_name] = (container1 [target_name] or 0) + amount
|
||||
end
|
||||
end
|
||||
local somar_habilidades = function(container1, container2)
|
||||
for spellid, habilidade in pairs (container2._ActorTable) do
|
||||
for spellid, habilidade in pairs(container2._ActorTable) do
|
||||
local habilidade_tabela1 = container1:PegaHabilidade (spellid, true, nil, false)
|
||||
somar_alvos (habilidade_tabela1.targets, habilidade.targets)
|
||||
somar_keys (habilidade, habilidade_tabela1)
|
||||
@@ -2506,7 +2506,7 @@ function atributo_misc:r_connect_shadow (actor, no_refresh, combat_object)
|
||||
shadow.spell_cast = {}
|
||||
end
|
||||
|
||||
for spellid, amount in pairs (actor.spell_cast) do
|
||||
for spellid, amount in pairs(actor.spell_cast) do
|
||||
shadow.spell_cast [spellid] = (shadow.spell_cast [spellid] or 0) + amount
|
||||
end
|
||||
end
|
||||
@@ -2572,7 +2572,7 @@ function atributo_misc:r_connect_shadow (actor, no_refresh, combat_object)
|
||||
|
||||
shadow.debuff_uptime = shadow.debuff_uptime + actor.debuff_uptime
|
||||
|
||||
for target_name, amount in pairs (actor.debuff_uptime_targets) do
|
||||
for target_name, amount in pairs(actor.debuff_uptime_targets) do
|
||||
if (_type(amount) == "table") then --boss debuff
|
||||
local t = shadow.debuff_uptime_targets [target_name]
|
||||
if (not t) then
|
||||
@@ -2609,16 +2609,16 @@ function atributo_misc:r_connect_shadow (actor, no_refresh, combat_object)
|
||||
somar_alvos (shadow.interrupt_targets, actor.interrupt_targets)
|
||||
somar_habilidades (shadow.interrupt_spells, actor.interrupt_spells)
|
||||
|
||||
for spellid, habilidade in pairs (actor.interrupt_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(actor.interrupt_spells._ActorTable) do
|
||||
local habilidade_shadow = shadow.interrupt_spells:PegaHabilidade (spellid, true, nil, true)
|
||||
|
||||
habilidade_shadow.interrompeu_oque = habilidade_shadow.interrompeu_oque or {}
|
||||
|
||||
for _spellid, amount in pairs (habilidade.interrompeu_oque) do
|
||||
for _spellid, amount in pairs(habilidade.interrompeu_oque) do
|
||||
habilidade_shadow.interrompeu_oque [_spellid] = (habilidade_shadow.interrompeu_oque [_spellid] or 0) + amount
|
||||
end
|
||||
end
|
||||
for spellid, amount in pairs (actor.interrompeu_oque) do
|
||||
for spellid, amount in pairs(actor.interrompeu_oque) do
|
||||
shadow.interrompeu_oque [spellid] = (shadow.interrompeu_oque [spellid] or 0) + amount
|
||||
end
|
||||
end
|
||||
@@ -2659,15 +2659,15 @@ function atributo_misc:r_connect_shadow (actor, no_refresh, combat_object)
|
||||
somar_alvos (shadow.dispell_targets, actor.dispell_targets)
|
||||
somar_habilidades (shadow.dispell_spells, actor.dispell_spells)
|
||||
|
||||
for spellid, habilidade in pairs (actor.dispell_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(actor.dispell_spells._ActorTable) do
|
||||
local habilidade_shadow = shadow.dispell_spells:PegaHabilidade (spellid, true, nil, true)
|
||||
habilidade_shadow.dispell_oque = habilidade_shadow.dispell_oque or {}
|
||||
for _spellid, amount in pairs (habilidade.dispell_oque) do
|
||||
for _spellid, amount in pairs(habilidade.dispell_oque) do
|
||||
habilidade_shadow.dispell_oque [_spellid] = (habilidade_shadow.dispell_oque [_spellid] or 0) + amount
|
||||
end
|
||||
end
|
||||
|
||||
for spellid, amount in pairs (actor.dispell_oque) do
|
||||
for spellid, amount in pairs(actor.dispell_oque) do
|
||||
shadow.dispell_oque [spellid] = (shadow.dispell_oque [spellid] or 0) + amount
|
||||
end
|
||||
end
|
||||
@@ -2689,14 +2689,14 @@ function atributo_misc:r_connect_shadow (actor, no_refresh, combat_object)
|
||||
somar_alvos (shadow.cc_break_targets, actor.cc_break_targets)
|
||||
somar_habilidades (shadow.cc_break_spells, actor.cc_break_spells)
|
||||
|
||||
for spellid, habilidade in pairs (actor.cc_break_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(actor.cc_break_spells._ActorTable) do
|
||||
local habilidade_shadow = shadow.cc_break_spells:PegaHabilidade (spellid, true, nil, true)
|
||||
habilidade_shadow.cc_break_oque = habilidade_shadow.cc_break_oque or {}
|
||||
for _spellid, amount in pairs (habilidade.cc_break_oque) do
|
||||
for _spellid, amount in pairs(habilidade.cc_break_oque) do
|
||||
habilidade_shadow.cc_break_oque [_spellid] = (habilidade_shadow.cc_break_oque [_spellid] or 0) + amount
|
||||
end
|
||||
end
|
||||
for spellid, amount in pairs (actor.cc_break_oque) do
|
||||
for spellid, amount in pairs(actor.cc_break_oque) do
|
||||
shadow.cc_break_oque [spellid] = (shadow.cc_break_oque [spellid] or 0) + amount
|
||||
end
|
||||
end
|
||||
@@ -2857,7 +2857,7 @@ end
|
||||
atributo_misc.__add = function(tabela1, tabela2)
|
||||
|
||||
if (tabela2.spell_cast) then
|
||||
for spellid, amount in pairs (tabela2.spell_cast) do
|
||||
for spellid, amount in pairs(tabela2.spell_cast) do
|
||||
tabela1.spell_cast [spellid] = (tabela1.spell_cast [spellid] or 0) + amount
|
||||
end
|
||||
end
|
||||
@@ -2865,14 +2865,14 @@ atributo_misc.__add = function(tabela1, tabela2)
|
||||
if (tabela2.cc_done) then
|
||||
tabela1.cc_done = tabela1.cc_done + tabela2.cc_done
|
||||
|
||||
for target_name, amount in pairs (tabela2.cc_done_targets) do
|
||||
for target_name, amount in pairs(tabela2.cc_done_targets) do
|
||||
tabela1.cc_done_targets [target_name] = (tabela1.cc_done_targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.cc_done_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.cc_done_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.cc_done_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
@@ -2892,24 +2892,24 @@ atributo_misc.__add = function(tabela1, tabela2)
|
||||
--total de interrupts
|
||||
tabela1.interrupt = tabela1.interrupt + tabela2.interrupt
|
||||
--soma o interrompeu o que
|
||||
for spellid, amount in pairs (tabela2.interrompeu_oque) do
|
||||
for spellid, amount in pairs(tabela2.interrompeu_oque) do
|
||||
tabela1.interrompeu_oque [spellid] = (tabela1.interrompeu_oque [spellid] or 0) + amount
|
||||
end
|
||||
--soma os containers de alvos
|
||||
for target_name, amount in pairs (tabela2.interrupt_targets) do
|
||||
for target_name, amount in pairs(tabela2.interrupt_targets) do
|
||||
tabela1.interrupt_targets [target_name] = (tabela1.interrupt_targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
--soma o container de habilidades
|
||||
for spellid, habilidade in pairs (tabela2.interrupt_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.interrupt_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.interrupt_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
habilidade_tabela1.interrompeu_oque = habilidade_tabela1.interrompeu_oque or {}
|
||||
for _spellid, amount in pairs (habilidade.interrompeu_oque) do
|
||||
for _spellid, amount in pairs(habilidade.interrompeu_oque) do
|
||||
habilidade_tabela1.interrompeu_oque [_spellid] = (habilidade_tabela1.interrompeu_oque [_spellid] or 0) + amount
|
||||
end
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
@@ -2927,14 +2927,14 @@ atributo_misc.__add = function(tabela1, tabela2)
|
||||
|
||||
tabela1.buff_uptime = tabela1.buff_uptime + tabela2.buff_uptime
|
||||
|
||||
for target_name, amount in pairs (tabela2.buff_uptime_targets) do
|
||||
for target_name, amount in pairs(tabela2.buff_uptime_targets) do
|
||||
tabela1.buff_uptime_targets [target_name] = (tabela1.buff_uptime_targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.buff_uptime_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.buff_uptime_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.buff_uptime_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
@@ -2960,7 +2960,7 @@ atributo_misc.__add = function(tabela1, tabela2)
|
||||
|
||||
tabela1.debuff_uptime = tabela1.debuff_uptime + tabela2.debuff_uptime
|
||||
|
||||
for target_name, amount in pairs (tabela2.debuff_uptime_targets) do
|
||||
for target_name, amount in pairs(tabela2.debuff_uptime_targets) do
|
||||
if (_type(amount) == "table") then --boss debuff
|
||||
local t = tabela1.debuff_uptime_targets [target_name]
|
||||
if (not t) then
|
||||
@@ -2976,10 +2976,10 @@ atributo_misc.__add = function(tabela1, tabela2)
|
||||
end
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.debuff_uptime_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.debuff_uptime_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.debuff_uptime_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
@@ -2996,14 +2996,14 @@ atributo_misc.__add = function(tabela1, tabela2)
|
||||
|
||||
tabela1.cooldowns_defensive = tabela1.cooldowns_defensive + tabela2.cooldowns_defensive
|
||||
|
||||
for target_name, amount in pairs (tabela2.cooldowns_defensive_targets) do
|
||||
for target_name, amount in pairs(tabela2.cooldowns_defensive_targets) do
|
||||
tabela1.cooldowns_defensive_targets [target_name] = (tabela1.cooldowns_defensive_targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.cooldowns_defensive_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.cooldowns_defensive_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.cooldowns_defensive_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
@@ -3020,14 +3020,14 @@ atributo_misc.__add = function(tabela1, tabela2)
|
||||
|
||||
tabela1.ress = tabela1.ress + tabela2.ress
|
||||
|
||||
for target_name, amount in pairs (tabela2.ress_targets) do
|
||||
for target_name, amount in pairs(tabela2.ress_targets) do
|
||||
tabela1.ress_targets [target_name] = (tabela1.ress_targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.ress_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.ress_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.ress_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
@@ -3046,27 +3046,27 @@ atributo_misc.__add = function(tabela1, tabela2)
|
||||
|
||||
tabela1.dispell = tabela1.dispell + tabela2.dispell
|
||||
|
||||
for target_name, amount in pairs (tabela2.dispell_targets) do
|
||||
for target_name, amount in pairs(tabela2.dispell_targets) do
|
||||
tabela1.dispell_targets [target_name] = (tabela1.dispell_targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.dispell_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.dispell_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.dispell_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
habilidade_tabela1.dispell_oque = habilidade_tabela1.dispell_oque or {}
|
||||
|
||||
for _spellid, amount in pairs (habilidade.dispell_oque) do
|
||||
for _spellid, amount in pairs(habilidade.dispell_oque) do
|
||||
habilidade_tabela1.dispell_oque [_spellid] = (habilidade_tabela1.dispell_oque [_spellid] or 0) + amount
|
||||
end
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
somar_keys (habilidade, habilidade_tabela1)
|
||||
end
|
||||
|
||||
for spellid, amount in pairs (tabela2.dispell_oque) do
|
||||
for spellid, amount in pairs(tabela2.dispell_oque) do
|
||||
tabela1.dispell_oque [spellid] = (tabela1.dispell_oque [spellid] or 0) + amount
|
||||
end
|
||||
|
||||
@@ -3083,26 +3083,26 @@ atributo_misc.__add = function(tabela1, tabela2)
|
||||
|
||||
tabela1.cc_break = tabela1.cc_break + tabela2.cc_break
|
||||
|
||||
for target_name, amount in pairs (tabela2.cc_break_targets) do
|
||||
for target_name, amount in pairs(tabela2.cc_break_targets) do
|
||||
tabela1.cc_break_targets [target_name] = (tabela1.cc_break_targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.cc_break_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.cc_break_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.cc_break_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
habilidade_tabela1.cc_break_oque = habilidade_tabela1.cc_break_oque or {}
|
||||
for _spellid, amount in pairs (habilidade.cc_break_oque) do
|
||||
for _spellid, amount in pairs(habilidade.cc_break_oque) do
|
||||
habilidade_tabela1.cc_break_oque [_spellid] = (habilidade_tabela1.cc_break_oque [_spellid] or 0) + amount
|
||||
end
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) + amount
|
||||
end
|
||||
|
||||
somar_keys (habilidade, habilidade_tabela1)
|
||||
end
|
||||
|
||||
for spellid, amount in pairs (tabela2.cc_break_oque) do
|
||||
for spellid, amount in pairs(tabela2.cc_break_oque) do
|
||||
tabela1.cc_break_oque [spellid] = (tabela1.cc_break_oque [spellid] or 0) + amount
|
||||
end
|
||||
end
|
||||
@@ -3111,7 +3111,7 @@ atributo_misc.__add = function(tabela1, tabela2)
|
||||
end
|
||||
|
||||
local subtrair_keys = function(habilidade, habilidade_tabela1)
|
||||
for key, value in pairs (habilidade) do
|
||||
for key, value in pairs(habilidade) do
|
||||
if (_type(value) == "number") then
|
||||
if (key ~= "id" and key ~= "spellschool") then
|
||||
habilidade_tabela1 [key] = (habilidade_tabela1 [key] or 0) - value
|
||||
@@ -3123,7 +3123,7 @@ end
|
||||
atributo_misc.__sub = function(tabela1, tabela2)
|
||||
|
||||
if (tabela2.spell_cast) then
|
||||
for spellid, amount in pairs (tabela2.spell_cast) do
|
||||
for spellid, amount in pairs(tabela2.spell_cast) do
|
||||
tabela1.spell_cast [spellid] = (tabela1.spell_cast [spellid] or 0) - amount
|
||||
end
|
||||
end
|
||||
@@ -3131,14 +3131,14 @@ atributo_misc.__sub = function(tabela1, tabela2)
|
||||
if (tabela2.cc_done) then
|
||||
tabela1.cc_done = tabela1.cc_done - tabela2.cc_done
|
||||
|
||||
for target_name, amount in pairs (tabela2.cc_done_targets) do
|
||||
for target_name, amount in pairs(tabela2.cc_done_targets) do
|
||||
tabela1.cc_done_targets [target_name] = (tabela1.cc_done_targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.cc_done_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.cc_done_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.cc_done_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
@@ -3150,24 +3150,24 @@ atributo_misc.__sub = function(tabela1, tabela2)
|
||||
--total de interrupts
|
||||
tabela1.interrupt = tabela1.interrupt - tabela2.interrupt
|
||||
--soma o interrompeu o que
|
||||
for spellid, amount in pairs (tabela2.interrompeu_oque) do
|
||||
for spellid, amount in pairs(tabela2.interrompeu_oque) do
|
||||
tabela1.interrompeu_oque [spellid] = (tabela1.interrompeu_oque [spellid] or 0) - amount
|
||||
end
|
||||
--soma os containers de alvos
|
||||
for target_name, amount in pairs (tabela2.interrupt_targets) do
|
||||
for target_name, amount in pairs(tabela2.interrupt_targets) do
|
||||
tabela1.interrupt_targets [target_name] = (tabela1.interrupt_targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
--soma o container de habilidades
|
||||
for spellid, habilidade in pairs (tabela2.interrupt_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.interrupt_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.interrupt_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
habilidade_tabela1.interrompeu_oque = habilidade_tabela1.interrompeu_oque or {}
|
||||
for _spellid, amount in pairs (habilidade.interrompeu_oque) do
|
||||
for _spellid, amount in pairs(habilidade.interrompeu_oque) do
|
||||
habilidade_tabela1.interrompeu_oque [_spellid] = (habilidade_tabela1.interrompeu_oque [_spellid] or 0) - amount
|
||||
end
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
@@ -3178,14 +3178,14 @@ atributo_misc.__sub = function(tabela1, tabela2)
|
||||
if (tabela2.buff_uptime) then
|
||||
tabela1.buff_uptime = tabela1.buff_uptime - tabela2.buff_uptime
|
||||
|
||||
for target_name, amount in pairs (tabela2.buff_uptime_targets) do
|
||||
for target_name, amount in pairs(tabela2.buff_uptime_targets) do
|
||||
tabela1.buff_uptime_targets [target_name] = (tabela1.buff_uptime_targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.buff_uptime_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.buff_uptime_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.buff_uptime_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
@@ -3196,7 +3196,7 @@ atributo_misc.__sub = function(tabela1, tabela2)
|
||||
if (tabela2.debuff_uptime) then
|
||||
tabela1.debuff_uptime = tabela1.debuff_uptime - tabela2.debuff_uptime
|
||||
|
||||
for target_name, amount in pairs (tabela2.debuff_uptime_targets) do
|
||||
for target_name, amount in pairs(tabela2.debuff_uptime_targets) do
|
||||
if (_type(amount) == "table") then --boss debuff
|
||||
local t = tabela1.debuff_uptime_targets [target_name]
|
||||
if (not t) then
|
||||
@@ -3212,10 +3212,10 @@ atributo_misc.__sub = function(tabela1, tabela2)
|
||||
end
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.debuff_uptime_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.debuff_uptime_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.debuff_uptime_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
@@ -3226,14 +3226,14 @@ atributo_misc.__sub = function(tabela1, tabela2)
|
||||
if (tabela2.cooldowns_defensive) then
|
||||
tabela1.cooldowns_defensive = tabela1.cooldowns_defensive - tabela2.cooldowns_defensive
|
||||
|
||||
for target_name, amount in pairs (tabela2.cooldowns_defensive_targets) do
|
||||
for target_name, amount in pairs(tabela2.cooldowns_defensive_targets) do
|
||||
tabela1.cooldowns_defensive_targets [target_name] = (tabela1.cooldowns_defensive_targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.cooldowns_defensive_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.cooldowns_defensive_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.cooldowns_defensive_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
@@ -3244,14 +3244,14 @@ atributo_misc.__sub = function(tabela1, tabela2)
|
||||
if (tabela2.ress) then
|
||||
tabela1.ress = tabela1.ress - tabela2.ress
|
||||
|
||||
for target_name, amount in pairs (tabela2.ress_targets) do
|
||||
for target_name, amount in pairs(tabela2.ress_targets) do
|
||||
tabela1.ress_targets [target_name] = (tabela1.ress_targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.ress_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.ress_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.ress_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
@@ -3262,27 +3262,27 @@ atributo_misc.__sub = function(tabela1, tabela2)
|
||||
if (tabela2.dispell) then
|
||||
tabela1.dispell = tabela1.dispell - tabela2.dispell
|
||||
|
||||
for target_name, amount in pairs (tabela2.dispell_targets) do
|
||||
for target_name, amount in pairs(tabela2.dispell_targets) do
|
||||
tabela1.dispell_targets [target_name] = (tabela1.dispell_targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.dispell_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.dispell_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.dispell_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
habilidade_tabela1.dispell_oque = habilidade_tabela1.dispell_oque or {}
|
||||
|
||||
for _spellid, amount in pairs (habilidade.dispell_oque) do
|
||||
for _spellid, amount in pairs(habilidade.dispell_oque) do
|
||||
habilidade_tabela1.dispell_oque [_spellid] = (habilidade_tabela1.dispell_oque [_spellid] or 0) - amount
|
||||
end
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
subtrair_keys (habilidade, habilidade_tabela1)
|
||||
end
|
||||
|
||||
for spellid, amount in pairs (tabela2.dispell_oque) do
|
||||
for spellid, amount in pairs(tabela2.dispell_oque) do
|
||||
tabela1.dispell_oque [spellid] = (tabela1.dispell_oque [spellid] or 0) - amount
|
||||
end
|
||||
end
|
||||
@@ -3291,26 +3291,26 @@ atributo_misc.__sub = function(tabela1, tabela2)
|
||||
|
||||
tabela1.cc_break = tabela1.cc_break - tabela2.cc_break
|
||||
|
||||
for target_name, amount in pairs (tabela2.cc_break_targets) do
|
||||
for target_name, amount in pairs(tabela2.cc_break_targets) do
|
||||
tabela1.cc_break_targets [target_name] = (tabela1.cc_break_targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
for spellid, habilidade in pairs (tabela2.cc_break_spells._ActorTable) do
|
||||
for spellid, habilidade in pairs(tabela2.cc_break_spells._ActorTable) do
|
||||
local habilidade_tabela1 = tabela1.cc_break_spells:PegaHabilidade (spellid, true, nil, false)
|
||||
|
||||
habilidade_tabela1.cc_break_oque = habilidade_tabela1.cc_break_oque or {}
|
||||
for _spellid, amount in pairs (habilidade.cc_break_oque) do
|
||||
for _spellid, amount in pairs(habilidade.cc_break_oque) do
|
||||
habilidade_tabela1.cc_break_oque [_spellid] = (habilidade_tabela1.cc_break_oque [_spellid] or 0) - amount
|
||||
end
|
||||
|
||||
for target_name, amount in pairs (habilidade.targets) do
|
||||
for target_name, amount in pairs(habilidade.targets) do
|
||||
habilidade_tabela1.targets [target_name] = (habilidade_tabela1.targets [target_name] or 0) - amount
|
||||
end
|
||||
|
||||
subtrair_keys (habilidade, habilidade_tabela1)
|
||||
end
|
||||
|
||||
for spellid, amount in pairs (tabela2.cc_break_oque) do
|
||||
for spellid, amount in pairs(tabela2.cc_break_oque) do
|
||||
tabela1.cc_break_oque [spellid] = (tabela1.cc_break_oque [spellid] or 0) - amount
|
||||
end
|
||||
end
|
||||
|
||||
@@ -474,7 +474,7 @@
|
||||
return
|
||||
end
|
||||
|
||||
pet_tooltip_frame:SetOwner (WorldFrame, "ANCHOR_NONE")
|
||||
pet_tooltip_frame:SetOwner(WorldFrame, "ANCHOR_NONE")
|
||||
pet_tooltip_frame:SetHyperlink ("unit:" .. serial or "")
|
||||
|
||||
Details.tabela_vigente.raid_roster_indexed = Details.tabela_vigente.raid_roster_indexed or {}
|
||||
|
||||
@@ -93,7 +93,7 @@ function historico:adicionar_overall (tabela)
|
||||
local combatTime = tabela:GetCombatTime()
|
||||
local combatType = tabela:GetCombatType()
|
||||
|
||||
tinsert (_detalhes.tabela_overall.segments_added, 1, {name = combatName, elapsed = combatTime, clock = this_clock, type = combatType})
|
||||
tinsert(_detalhes.tabela_overall.segments_added, 1, {name = combatName, elapsed = combatTime, clock = this_clock, type = combatType})
|
||||
|
||||
if (#_detalhes.tabela_overall.segments_added > 40) then
|
||||
tremove (_detalhes.tabela_overall.segments_added, 41)
|
||||
@@ -142,7 +142,7 @@ function _detalhes:ScheduleAddCombatToOverall (combat) --deprecated (15/03/2019)
|
||||
local canAdd = _detalhes:CanAddCombatToOverall (combat)
|
||||
if (canAdd) then
|
||||
_detalhes.schedule_add_to_overall = _detalhes.schedule_add_to_overall or {}
|
||||
tinsert (_detalhes.schedule_add_to_overall, combat)
|
||||
tinsert(_detalhes.schedule_add_to_overall, combat)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
@@ -56,7 +56,7 @@ local _
|
||||
end
|
||||
|
||||
function container_habilidades:ListActors()
|
||||
return pairs (self._ActorTable)
|
||||
return pairs(self._ActorTable)
|
||||
end
|
||||
|
||||
function container_habilidades:GetOrCreateSpell(id, shouldCreate, token)
|
||||
|
||||
@@ -11,7 +11,7 @@ local _detalhes = _G._detalhes
|
||||
local SharedMedia = LibStub:GetLibrary("LibSharedMedia-3.0")
|
||||
|
||||
function _detalhes:ResetInstanceConfig (maintainsnap)
|
||||
for key, value in pairs (_detalhes.instance_defaults) do
|
||||
for key, value in pairs(_detalhes.instance_defaults) do
|
||||
if (type(value) == "table") then
|
||||
self [key] = Details.CopyTable (value)
|
||||
else
|
||||
@@ -57,7 +57,7 @@ _detalhes.instance_skin_ignored_values = {
|
||||
}
|
||||
|
||||
function _detalhes:ResetInstanceConfigKeepingValues (maintainsnap)
|
||||
for key, value in pairs (_detalhes.instance_defaults) do
|
||||
for key, value in pairs(_detalhes.instance_defaults) do
|
||||
if (not _detalhes.instance_skin_ignored_values [key]) then
|
||||
if (type(value) == "table") then
|
||||
self [key] = Details.CopyTable (value)
|
||||
@@ -75,7 +75,7 @@ function _detalhes:ResetInstanceConfigKeepingValues (maintainsnap)
|
||||
end
|
||||
|
||||
function _detalhes:LoadInstanceConfig()
|
||||
for key, value in pairs (_detalhes.instance_defaults) do
|
||||
for key, value in pairs(_detalhes.instance_defaults) do
|
||||
if (self [key] == nil) then
|
||||
if (type(value) == "table") then
|
||||
self [key] = Details.CopyTable (_detalhes.instance_defaults [key])
|
||||
@@ -84,7 +84,7 @@ function _detalhes:LoadInstanceConfig()
|
||||
end
|
||||
|
||||
elseif (type(value) == "table") then
|
||||
for key2, value2 in pairs (value) do
|
||||
for key2, value2 in pairs(value) do
|
||||
if (self [key] [key2] == nil) then
|
||||
if (type(value2) == "table") then
|
||||
self [key] [key2] = Details.CopyTable (_detalhes.instance_defaults [key] [key2])
|
||||
|
||||
Reference in New Issue
Block a user