but it’s always the generic question-mark icon*. Any way to get that to show either bloodthirst or devastate as a tooltip depending on which is known? could I do it with some sort of funky lua script?
Edit:
Technically it’s the generic question mark if I know Devastate but Bloodthirst is listed first. If I list Devastate first, it shows properly.
The only thing that I can think of is a self-authoring macro that changes what is cast (out of combat only) based on your SPEC or based on IsSpellKnown() (or maybe it’s SpellIsKnown() - I keep having to look that one up).
I’m not sure, however, if Classic (or TBC for that matter) support EditMacro() or IsSpellKnown().
That’s just the thing…there aren’t two setups. There is only one setup, and to change, I have to go to the trainer, pay 50g, and it resets my talents. There are three talent trees, but only ever one “spec” in BCC.
Here’s something I just quickly threw together. Untested.
local spells =
{
["Presence of Mind"] = "Interface//Icons//spell_mage_presenceofmind"
["Living Bomb"] = "Interface//Icons//Ability_Mage_LivingBomb"
}
local function updateMacro()
if (InCombatLockdown()) then
-- in combat, try again in 30 sec
C_Timer.After(30, updateMacro)
else
-- not in combat, proceed
for spell, icon in pairs(spells) do
if (GetSpellInfo(spell)) then
EditMacro("myMacro", nil, icon, "/cast "..spell)
break
end
end
end
end
-- initialize when logging in or reloading
local f = CreateFrame("Frame")
f:SetScript("OnEvent", updateMacro)
f:RegisterEvent("PLAYER_LOGIN")
-- maybe this is an easy way to capture talent changes?
f:RegisterEvent("PLAYER_TALENT_UPDATE")
-- if that didn't do it, then this is a more complicated way to catch talent changes.
local needHook = true
local function applyHook()
if (needHook) then
PlayerTalentFrame:HookScript("OnHide", updateMacro)
needHook = false -- in case another addon calls TalentFrame_LoadUI() repeatedly
end
end
if (PlayerTalentFrame) then
-- another addon already initialized the frame; so hook it!
applyHook()
else
-- wait for the frame to be initialized, then hook it!
hooksecurefunc("TalentFrame_LoadUI", applyHook)
end
Code tags? Smart quotes? I don’t follow. I have been out for a while, so these are new concepts to me. And yes, that template is what I found to base the macro on. I went down this path of finding out if the row/col values were right and landed there. I got a lot of help from this forum back in the day (when TBC was original), so I like to give back when I think I can.