Feehza
04-18-2010, 07:28 PM
Another modification for Pitbull4: better Health Updates.
Since no InstantHealth or QuickHealth is available for Pitbull4 i included my own healthbar update for Pitbull4.
Now the healthbar updates are fast as Grid+QuickHealth. (Updates fires with COMBAT_LOG_EVENT_UNFILTERED)
AddOns\Pitbull4_HealthBar\HealthBar.lua (Make sure you dont edit the other HealthBar.lua in AddOns\PitBull4\Modules\HealthBar\HealthBar.lua
search for:
timerFrame:SetScript("OnUpdate", function()
if next(guids_to_update) then
for frame in PitBull4:IterateFrames() do
if guids_to_update[frame.guid] then
PitBull4_HealthBar:Update(frame)
end
end
wipe(guids_to_update)
end
--[[ Currently the WoW Client isn't actually doing fast updates for health.
-- It's unclear if this is a bug or a change in feature. Disabling the
-- code to support this for now since it's a waste of CPU time for no benefit.
for frame in PitBull4:IterateFramesForGUIDs(PLAYER_GUID, UnitGUID("pet")) do
if not frame.is_wacky then
PitBull4_HealthBar:Update(frame)
end
end
--]]
end)
replace it with:
function refreshHealthBar_OnEvent()
for frame in PitBull4:IterateFrames() do
if not frame.is_wacky then
PitBull4_HealthBar:Update(frame)
end
end
wipe(guids_to_update)
end
local Healthbar_refresh_frame = CreateFrame("Frame","refreshHealthBar",UIParent)
Healthbar_refresh_frame:SetScript("OnEvent", refreshHealthBar_OnEvent)
Healthbar_refresh_frame:RegisterEvent("COMBAT_LOG_EVENT_UNFILTERED")
You can download the necessary file here: http://tinyurl.com/y2a55kk
Since no InstantHealth or QuickHealth is available for Pitbull4 i included my own healthbar update for Pitbull4.
Now the healthbar updates are fast as Grid+QuickHealth. (Updates fires with COMBAT_LOG_EVENT_UNFILTERED)
AddOns\Pitbull4_HealthBar\HealthBar.lua (Make sure you dont edit the other HealthBar.lua in AddOns\PitBull4\Modules\HealthBar\HealthBar.lua
search for:
timerFrame:SetScript("OnUpdate", function()
if next(guids_to_update) then
for frame in PitBull4:IterateFrames() do
if guids_to_update[frame.guid] then
PitBull4_HealthBar:Update(frame)
end
end
wipe(guids_to_update)
end
--[[ Currently the WoW Client isn't actually doing fast updates for health.
-- It's unclear if this is a bug or a change in feature. Disabling the
-- code to support this for now since it's a waste of CPU time for no benefit.
for frame in PitBull4:IterateFramesForGUIDs(PLAYER_GUID, UnitGUID("pet")) do
if not frame.is_wacky then
PitBull4_HealthBar:Update(frame)
end
end
--]]
end)
replace it with:
function refreshHealthBar_OnEvent()
for frame in PitBull4:IterateFrames() do
if not frame.is_wacky then
PitBull4_HealthBar:Update(frame)
end
end
wipe(guids_to_update)
end
local Healthbar_refresh_frame = CreateFrame("Frame","refreshHealthBar",UIParent)
Healthbar_refresh_frame:SetScript("OnEvent", refreshHealthBar_OnEvent)
Healthbar_refresh_frame:RegisterEvent("COMBAT_LOG_EVENT_UNFILTERED")
You can download the necessary file here: http://tinyurl.com/y2a55kk