X-Git-Url: https://www.aleksib.fi/git/wowui.git/blobdiff_plain/970f9377d0344b60ab9b77796135726bfecfdd20..0da3db7331fa69ddcc358d8e0b4d1eab64056235:/OmaAB/ExpBar.lua diff --git a/OmaAB/ExpBar.lua b/OmaAB/ExpBar.lua index 021ac76..ca2f5a0 100644 --- a/OmaAB/ExpBar.lua +++ b/OmaAB/ExpBar.lua @@ -57,7 +57,7 @@ local function expBar() frame:SetScript("OnEvent", function(self, event) if event == "PLAYER_XP_UPDATE" or event == "PLAYER_LEVEL_UP" then updateXP(); - elseif event == "PLAYER_UPDATE_RESTING" then + elseif event == "PLAYER_UPDATE_RESTING" or event == "PLAYER_ENTERING_WORLD" then if IsResting() then running = true; CTimerAfter(6, updater); @@ -70,6 +70,7 @@ local function expBar() frame:RegisterEvent("PLAYER_XP_UPDATE"); frame:RegisterEvent("PLAYER_LEVEL_UP"); frame:RegisterEvent("PLAYER_UPDATE_RESTING"); + frame:RegisterEvent("PLAYER_ENTERING_WORLD"); -- from FrameXML/MainMenuBar.lua frame:SetScript("OnEnter", function(frame) frame.text:Show(); ExhaustionToolTipText(); end); frame:SetScript("OnLeave", function(frame) frame.text:Hide(); GameTooltip:Hide(); end);