diff --git a/Core/Player.lua b/Core/Player.lua index 129f1f2..0cdabae 100755 --- a/Core/Player.lua +++ b/Core/Player.lua @@ -16,7 +16,7 @@ ham.Player.new = function() local spells = {} for i, spell in ipairs(HAMDB.activatedSpells) do - if IsSpellKnown(spell) then + if IsSpellKnown(spell) or IsSpellKnown(spell, true) then table.insert(spells, spell) end end diff --git a/Core/Spells.lua b/Core/Spells.lua index 2466bc7..9e81c3e 100755 --- a/Core/Spells.lua +++ b/Core/Spells.lua @@ -5,7 +5,7 @@ local isRetail = (WOW_PROJECT_ID == WOW_PROJECT_MAINLINE) ham.crimsonVialSpell = 185311 ham.renewal = 108238 ham.exhilaration = 109304 -ham.fortitudeOfTheBear = 272679 +ham.fortitudeOfTheBear = 388035 ham.bitterImmunity = 383762 ham.desperatePrayer = 19236 ham.expelHarm = 322101 diff --git a/FrameXML/InterfaceOptionsFrame.lua b/FrameXML/InterfaceOptionsFrame.lua index bd6666f..53f2995 100644 --- a/FrameXML/InterfaceOptionsFrame.lua +++ b/FrameXML/InterfaceOptionsFrame.lua @@ -414,7 +414,7 @@ function ham.settingsFrame:InitializeClassSpells(relativeTo) if next(ham.supportedSpells) ~= nil then local count = 0 for i, spell in ipairs(ham.supportedSpells) do - if IsSpellKnown(spell) then + if IsSpellKnown(spell) or IsSpellKnown(spell, true) then local name = C_Spell.GetSpellName(spell) local button = CreateFrame("CheckButton", nil, self.content, "InterfaceOptionsCheckButtonTemplate") diff --git a/code.lua b/code.lua index d56f3b2..caf1a9e 100755 --- a/code.lua +++ b/code.lua @@ -394,6 +394,7 @@ if isClassic == false then updateFrame:RegisterEvent("TRAIT_CONFIG_UPDATED") end updateFrame:RegisterEvent("PLAYER_REGEN_ENABLED") +updateFrame:RegisterEvent("UNIT_PET") updateFrame:SetScript("OnEvent", function(self, event, arg1, ...) -- when addon is loaded if event == "ADDON_LOADED" and arg1 == addonName then @@ -410,6 +411,10 @@ updateFrame:SetScript("OnEvent", function(self, event, arg1, ...) if event == "BAG_UPDATE" then onBagUpdate() -- on loading/reloading + elseif event == "UNIT_PET" then + log("event: UNIT_PET") + MakeMacro() + -- when pet is called elseif event == "PLAYER_ENTERING_WORLD" then log("event: PLAYER_ENTERING_WORLD") MakeMacro()