Conditional targetenemy not working

I’d like to not have targetenemy not defaulting in my macro, but be able to selectively enable it.

I tried using:
/targetenemy [mod:shift, noharm][mod:shift, dead]

However, this targets the enemy without holding shift.

What am I missing?

Are mods and option for that command? Not every command allows mods.

it is my understanding that you cant have the same mod in a string

I’m just referencing wowpedia which shows

/targetenemy [options] direction

where options are “secure command options”.

These include “mod”. However, I don’t know where else to check. Right now it seems they just don’t work here.

I guess I’ll try a “click” and put these in another macro (assuming click will use the mod).

OK, just learned that there are spells which automatically target an enemy. For example, I am doing macro on hunter and standing near target dummy which is not targeted. However, cast Serpent Sting and it selects the dummy and fires. Same thing for Shrapnel Bomb.

So even with no targetenemy in the macro, I end up targeting distant enemy when my current target dies.

Very frustrating.

You could use the GSE Option - “require target to use”. This will stop your macro from firing if you don’t have an active target irrespective of what is in your macro.

It’s the Target Protection line on the Minimapicon/LDB menu.