Wand macro question

Wand macro question

by Winstons » Thu Nov 19, 2015 12:12 am

Hi guys, I'm pretty unfamiliar with how macros work, so I'm hoping some wiser heads can advise me here.

I'm looking to create a macro for my wand attack, that will target a specific type of totem if it is in range, and if there isn't one, to attack my current target. Is this possible? A biscuit is available as a prize.
Player vs Herbs - The Trailer! https://www.youtube.com/watch?v=aZIUqT1wmOs
Winstons - Level 60 Undead Priest <Slacker's Corner>
Hiltts - Level 29 Human Warlock <Blessed Be The Thingy>
Hilts - Level 33 Human Mage
Winstons
Sergeant
Sergeant
 

Re: Wand macro question

by Dreez » Sat Nov 28, 2015 2:33 pm

a macro that automatically tries to target any totem and casts wand is only possible with repeat functions and weird conditions that'll either make it fail to work or crash your client

however here's a macro that tries to target a specific totem by its name, if it exists wands it, if it doesn't exist targets your last enemy and casts wand
Code: Select all
/run d=CheckInteractDistance("target", 4) c=CastSpellByName u=UnitCreatureType("target") TargetByName("Grounding Totem") if (u=="totem" and d==1) then c("Shoot") else TargetLastEnemy() c("Shoot") end


edit: range check implemented
Dreez - PvP server
<Endzeit>
User avatar
Dreez
Knight-Lieutenant
Knight-Lieutenant
 

Re: Wand macro question

by Winstons » Sat Nov 28, 2015 4:46 pm

Hi again! Thanks once more. I created a very simple half-assed version of this that essentially just auto-targets totems, but this is much better, thank you.
Player vs Herbs - The Trailer! https://www.youtube.com/watch?v=aZIUqT1wmOs
Winstons - Level 60 Undead Priest <Slacker's Corner>
Hiltts - Level 29 Human Warlock <Blessed Be The Thingy>
Hilts - Level 33 Human Mage
Winstons
Sergeant
Sergeant
 


Return to Addons & macros