I know.. I know.. There are add-ons that already do this. But hey! We’re always looking for unique macros and plus, this has the potential of being included in other macros (e.g. /cast Hunter’s Mark, /PetAttack macro’s)
Anyways, I owe this macro to Gello in Underhill on Hyjal from the official UI/Macro Forums and promise to give proper credit as soon as their back operational. In the mean time, I hope you find this as useful as I am.
/run local Tt,t,c=Tt or {} for i=1,25 do t=string.match(GetTrackingInfo(i) or “”,”Track (.+)”) if t then t=gsub(t,”s$”,”") Tt[t]=i end end c=UnitCreatureType(“target”) if Tt[c or ""] then SetTracking(Tt[c]) print(“Tracking “..c) end




