WoW:API AttackTarget: Difference between revisions

no edit summary
No edit summary
No edit summary
Line 30: Line 30:


This is actually a toggle.  If not currently attacking, it will initiate attack.  If currently attacking, it will stop attacking.
This is actually a toggle.  If not currently attacking, it will initiate attack.  If currently attacking, it will stop attacking.
You can test your current attack "Action slot" using '''IsCurrentAction(actionSlot)''' for status (Attacking or Not)


''If you need a way to always engage auto-attack, rather than toggle it on or off, one workaround I've used is'' AssistUnit("player"); ''this will always attack if you have "Attack on assist" checked in the Advanced tab of the Interface Options panel. (Although, I should add that I've had trouble mixing this with ''TargetNearestEnemy()'' in the same macro - the "Assist" target info isn't updated fast enough I guess) -- [[User:JamesNeko|JamesNeko]] 07:03, 4 Mar 2006 (EST)''
''If you need a way to always engage auto-attack, rather than toggle it on or off, one workaround I've used is'' AssistUnit("player"); ''this will always attack if you have "Attack on assist" checked in the Advanced tab of the Interface Options panel. (Although, I should add that I've had trouble mixing this with ''TargetNearestEnemy()'' in the same macro - the "Assist" target info isn't updated fast enough I guess) -- [[User:JamesNeko|JamesNeko]] 07:03, 4 Mar 2006 (EST)''