mirror of
https://github.com/brues-code/pfUI.git
synced 2026-09-27 09:56:03 +00:00
unitframes: optimize memory usage of aggro scanner
This commit is contained in:
+3
-1
@@ -132,7 +132,9 @@ function pfUI.api.UnitHasAggro(unit)
|
||||
return aggrodata[unit].state
|
||||
end
|
||||
|
||||
aggrodata[unit] = { check = GetTime(), state = 0}
|
||||
aggrodata[unit] = aggrodata[unit] or { }
|
||||
aggrodata[unit].check = GetTime()
|
||||
aggrodata[unit].state = 0
|
||||
|
||||
if UnitExists(unit) and UnitIsFriend(unit, "player") then
|
||||
for u in pairs(pfValidUnits) do
|
||||
|
||||
Reference in New Issue
Block a user