Code cleanup, framework update and bug fixes
This commit is contained in:
+4
-7
@@ -95,7 +95,6 @@
|
||||
|
||||
-- try get the current encounter name during the encounter
|
||||
local boss_found_not_registered = function(t, ZoneName, ZoneMapID, DifficultyID)
|
||||
|
||||
local boss_table = {
|
||||
index = 0,
|
||||
name = t[1],
|
||||
@@ -113,7 +112,6 @@
|
||||
end
|
||||
|
||||
local boss_found = function(index, name, zone, mapid, diff, encounterid)
|
||||
|
||||
local mapID = C_Map.GetBestMapForUnit ("player")
|
||||
local ejid
|
||||
if (mapID) then
|
||||
@@ -141,16 +139,16 @@
|
||||
id = encounterid,
|
||||
}
|
||||
|
||||
if (not Details:IsRaidRegistered (mapid) and Details.zone_type == "raid") then
|
||||
if (not Details:IsRaidRegistered(mapid) and Details.zone_type == "raid") then
|
||||
local boss_list = Details:GetCurrentDungeonBossListFromEJ()
|
||||
if (boss_list) then
|
||||
local ActorsContainer = Details.tabela_vigente [class_type_dano]._ActorTable
|
||||
local ActorsContainer = Details.tabela_vigente[class_type_dano]._ActorTable
|
||||
if (ActorsContainer) then
|
||||
for index, Actor in ipairs(ActorsContainer) do
|
||||
if (not Actor.grupo) then
|
||||
if (boss_list [Actor.nome]) then
|
||||
if (boss_list[Actor.nome]) then
|
||||
Actor.boss = true
|
||||
boss_table.bossimage = boss_list [Actor.nome][4]
|
||||
boss_table.bossimage = boss_list[Actor.nome][4]
|
||||
break
|
||||
end
|
||||
end
|
||||
@@ -1424,7 +1422,6 @@
|
||||
end
|
||||
|
||||
function Details:FlagActorsOnCommonFight()
|
||||
|
||||
local damage_container = Details.tabela_vigente [1]
|
||||
local healing_container = Details.tabela_vigente [2]
|
||||
local energy_container = Details.tabela_vigente [3]
|
||||
|
||||
+11
-6
@@ -5724,12 +5724,12 @@ local SPELL_POWER_PAIN = SPELL_POWER_PAIN or (PowerEnum and PowerEnum.Pain) or 1
|
||||
--load up data from saved variables for the account (shared among all the players' characters; this is not the Blizzard account, lol).
|
||||
Details222.LoadSavedVariables.SharedData()
|
||||
|
||||
--load data of the segments saved from latest game session
|
||||
Details222.LoadSavedVariables.CombatSegments()
|
||||
|
||||
--load the profiles
|
||||
Details:LoadConfig()
|
||||
|
||||
--load data of the segments saved from latest game session
|
||||
Details222.LoadSavedVariables.CombatSegments()
|
||||
|
||||
Details:UpdateParserGears()
|
||||
|
||||
--load auto run code
|
||||
@@ -5852,14 +5852,12 @@ local SPELL_POWER_PAIN = SPELL_POWER_PAIN or (PowerEnum and PowerEnum.Pain) or 1
|
||||
---@param text string the error to be logged
|
||||
local addToExitErrors = function(text)
|
||||
table.insert(exitErrors, 1, Details222.Date.GetDateForLogs() .. "|" .. text)
|
||||
table.remove(exitErrors, 10)
|
||||
table.remove(exitErrors, 11)
|
||||
end
|
||||
|
||||
---@type string current step of the logout process, used to log which is the current step when an error happens
|
||||
local currentStep = ""
|
||||
|
||||
Details222.AutoRunCode.OnLogout()
|
||||
|
||||
--save the time played on this class, run protected
|
||||
local savePlayTimeClass, savePlayTimeErrorText = pcall(function() Details.SavePlayTimeOnClass() end)
|
||||
|
||||
@@ -5964,6 +5962,13 @@ local SPELL_POWER_PAIN = SPELL_POWER_PAIN or (PowerEnum and PowerEnum.Pain) or 1
|
||||
_detalhes_database.nick_tag_cache = Details.CopyTable(_detalhes_database.nick_tag_cache)
|
||||
end
|
||||
xpcall(saveNicktabCache, logSaverError)
|
||||
|
||||
--save auto run code data
|
||||
tinsert(_detalhes_global.exit_log, "9 - Saving Auto Run Code.")
|
||||
local saveAutoRunCode = function()
|
||||
Details222.AutoRunCode.OnLogout()
|
||||
end
|
||||
xpcall(saveAutoRunCode, logSaverError)
|
||||
end) --end of saving data
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user