How to create a macro with [@player] and [@cursor]?

Hello! I am trying to build a macro that will place a Hunter traps at my cursor if I press the macro, or at my character’s feet [@player] if I hold down shift.

My current macro is
/cast [@cursor] Hi-Explosive Trap; [mod:shift] [@player] Hi-Explosive Trap

and this doesn’t work. Any ideas if I can get it to use both modifiers?

EDIT*

I seem to have brute forced the answer:

#showtooltip Hi-Explosive Trap
/cast [nomod, @cursor] Hi-Explosive Trap; [mod:shift, @player] Hi-Explosive Trap

:smiley:

1 Like

A quick explanation: macro conditions are evaluated right to left, and the first matching one is executed. So [@cursor] would take precedence over [mod:shift,@player]. You can also swap the two to have the shifted one first, that’ll work too, and you won’t need nomod, so you can save a bit of space (not important in this case, though).

1 Like
[this, and this]
[this] [or this]
#showtooltip
/cast [mod:shift,@player] [@cursor] Hi-Explosive Trap
5 Likes

Thank you both very interesting replies, this will help me a lot as build future macros, so appreciate it! :slight_smile:

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.