Fixed an issue with player names cache getting 'Unknown' from UnitName()
This commit is contained in:
@@ -125,6 +125,7 @@ frames\window_classcolor.lua
|
|||||||
frames\window_statistics.lua
|
frames\window_statistics.lua
|
||||||
frames\window_aura_tracker.lua
|
frames\window_aura_tracker.lua
|
||||||
frames\window_debug.lua
|
frames\window_debug.lua
|
||||||
|
frames\window_pro_file.lua
|
||||||
|
|
||||||
classes\class_error.lua
|
classes\class_error.lua
|
||||||
classes\class_spelltable.lua
|
classes\class_spelltable.lua
|
||||||
|
|||||||
@@ -19,8 +19,8 @@
|
|||||||
local addonName, Details222 = ...
|
local addonName, Details222 = ...
|
||||||
local version = GetBuildInfo()
|
local version = GetBuildInfo()
|
||||||
|
|
||||||
Details.build_counter = 12869
|
Details.build_counter = 12877
|
||||||
Details.alpha_build_counter = 12869 --if this is higher than the regular counter, use it instead
|
Details.alpha_build_counter = 12877 --if this is higher than the regular counter, use it instead
|
||||||
Details.dont_open_news = true
|
Details.dont_open_news = true
|
||||||
Details.game_version = version
|
Details.game_version = version
|
||||||
Details.userversion = version .. " " .. Details.build_counter
|
Details.userversion = version .. " " .. Details.build_counter
|
||||||
|
|||||||
+16
-3
@@ -635,7 +635,7 @@
|
|||||||
Details:Msg(Details.WhoAggroTimer.HitBy)
|
Details:Msg(Details.WhoAggroTimer.HitBy)
|
||||||
end
|
end
|
||||||
|
|
||||||
local spellInfo = C_Spell.GetSpellInfo(spellId)
|
--local spellInfo = C_Spell.GetSpellInfo(spellId)
|
||||||
Details222.StartCombat(sourceSerial, sourceName, sourceFlags, targetSerial, targetName, targetFlags)
|
Details222.StartCombat(sourceSerial, sourceName, sourceFlags, targetSerial, targetName, targetFlags)
|
||||||
else
|
else
|
||||||
--entrar em combate se for dot e for do jogador e o ultimo combate ter sido a mais de 10 segundos atr�s
|
--entrar em combate se for dot e for do jogador e o ultimo combate ter sido a mais de 10 segundos atr�s
|
||||||
@@ -5585,6 +5585,8 @@ local SPELL_POWER_PAIN = SPELL_POWER_PAIN or (PowerEnum and PowerEnum.Pain) or 1
|
|||||||
end
|
end
|
||||||
|
|
||||||
local update_persistant_unitname_cache = function()
|
local update_persistant_unitname_cache = function()
|
||||||
|
Details.UpdatePersistantCacheTimer = nil
|
||||||
|
|
||||||
local unitIdCache
|
local unitIdCache
|
||||||
|
|
||||||
if (IsInRaid()) then
|
if (IsInRaid()) then
|
||||||
@@ -5613,7 +5615,9 @@ local SPELL_POWER_PAIN = SPELL_POWER_PAIN or (PowerEnum and PowerEnum.Pain) or 1
|
|||||||
function Details.parser_functions:GROUP_ROSTER_UPDATE(...)
|
function Details.parser_functions:GROUP_ROSTER_UPDATE(...)
|
||||||
local bIsInGroup = IsInGroup() or IsInRaid()
|
local bIsInGroup = IsInGroup() or IsInRaid()
|
||||||
|
|
||||||
update_persistant_unitname_cache()
|
if (not Details.UpdatePersistantCacheTimer) then
|
||||||
|
Details.UpdatePersistantCacheTimer = C_Timer.NewTimer(2, update_persistant_unitname_cache)
|
||||||
|
end
|
||||||
|
|
||||||
if (not Details.in_group) then
|
if (not Details.in_group) then
|
||||||
Details.in_group = bIsInGroup
|
Details.in_group = bIsInGroup
|
||||||
@@ -5817,8 +5821,17 @@ local SPELL_POWER_PAIN = SPELL_POWER_PAIN or (PowerEnum and PowerEnum.Pain) or 1
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function Details.parser_functions:UNIT_NAME_UPDATE(...)
|
function Details.parser_functions:UNIT_NAME_UPDATE(unitId)
|
||||||
Details:SchedulePetUpdate(5)
|
Details:SchedulePetUpdate(5)
|
||||||
|
local unitGUID = UnitGUID(unitId)
|
||||||
|
if (unitGUID) then
|
||||||
|
if (unitGUID:match("^Pl")) then
|
||||||
|
local unitFullName = Details:GetFullName(unitId)
|
||||||
|
if (unitFullName) then
|
||||||
|
group_roster_name_cache[unitGUID] = unitFullName
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
function Details.parser_functions:PLAYER_TARGET_CHANGED(...)
|
function Details.parser_functions:PLAYER_TARGET_CHANGED(...)
|
||||||
|
|||||||
@@ -0,0 +1,6 @@
|
|||||||
|
|
||||||
|
local Details = Details
|
||||||
|
local addonName, Details222 = ...
|
||||||
|
---@type detailsframework
|
||||||
|
local detailsFramework = DetailsFramework
|
||||||
|
local _
|
||||||
+49
@@ -583,6 +583,55 @@ function Details222.StartUp.StartMeUp()
|
|||||||
|
|
||||||
Details.cached_specs[UnitGUID("player")] = GetSpecializationInfo(GetSpecialization() or 0)
|
Details.cached_specs[UnitGUID("player")] = GetSpecializationInfo(GetSpecialization() or 0)
|
||||||
|
|
||||||
|
if (GetExpansionLevel() == 2) then
|
||||||
|
if (not Details.data_wipes_exp["3"]) then
|
||||||
|
Details:Msg("New expansion detected, clearing data...")
|
||||||
|
Details:Destroy(Details.encounter_spell_pool or {})
|
||||||
|
Details:Destroy(Details.boss_mods_timers or {})
|
||||||
|
Details:Destroy(Details.spell_school_cache or {})
|
||||||
|
Details:Destroy(Details.spell_pool or {})
|
||||||
|
Details:Destroy(Details.npcid_pool or {})
|
||||||
|
Details:Destroy(Details.current_exp_raid_encounters or {})
|
||||||
|
Details.data_wipes_exp["3"] = true
|
||||||
|
|
||||||
|
Details.frame_background_color[1] = 0.0549
|
||||||
|
Details.frame_background_color[2] = 0.0549
|
||||||
|
Details.frame_background_color[3] = 0.0549
|
||||||
|
Details.frame_background_color[4] = 0.934
|
||||||
|
|
||||||
|
if (Details.breakdown_spell_tab.spellcontainer_headers.critpercent) then
|
||||||
|
Details.breakdown_spell_tab.spellcontainer_headers.critpercent.enabled = true
|
||||||
|
end
|
||||||
|
|
||||||
|
if (Details.breakdown_spell_tab.spellcontainer_headers.uptime) then
|
||||||
|
Details.breakdown_spell_tab.spellcontainer_headers.uptime.enabled = true
|
||||||
|
end
|
||||||
|
|
||||||
|
if (Details.breakdown_spell_tab.spellcontainer_headers.hits) then
|
||||||
|
Details.breakdown_spell_tab.spellcontainer_headers.hits.enabled = true
|
||||||
|
end
|
||||||
|
|
||||||
|
Details.breakdown_general.bar_texture = "You Are the Best!"
|
||||||
|
|
||||||
|
Details.tooltip.rounded_corner = false
|
||||||
|
|
||||||
|
local tooltipBarColor = Details.tooltip.bar_color
|
||||||
|
tooltipBarColor[1] = 0.129
|
||||||
|
tooltipBarColor[2] = 0.129
|
||||||
|
tooltipBarColor[3] = 0.129
|
||||||
|
tooltipBarColor[4] = 1
|
||||||
|
|
||||||
|
local tooltipBackgroundColor = Details.tooltip.background
|
||||||
|
tooltipBackgroundColor[1] = 0.054
|
||||||
|
tooltipBackgroundColor[2] = 0.054
|
||||||
|
tooltipBackgroundColor[3] = 0.054
|
||||||
|
tooltipBackgroundColor[4] = 0.8
|
||||||
|
|
||||||
|
Details.tooltip.fontshadow = true
|
||||||
|
Details.tooltip.fontsize = 11
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
Details.boss_mods_timers.encounter_timers_dbm = Details.boss_mods_timers.encounter_timers_dbm or {}
|
Details.boss_mods_timers.encounter_timers_dbm = Details.boss_mods_timers.encounter_timers_dbm or {}
|
||||||
Details.boss_mods_timers.encounter_timers_bw = Details.boss_mods_timers.encounter_timers_bw or {}
|
Details.boss_mods_timers.encounter_timers_bw = Details.boss_mods_timers.encounter_timers_bw or {}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user