WoW:API TargetNearestEnemy: Difference between revisions
Jump to navigation
Jump to search
m (Grammar fix) |
No edit summary |
||
Line 1: | Line 1: | ||
{{wowapi}} | {{wowapi}} | ||
{{protectedapi|2.0.1|}} | |||
Selects the nearest enemy as the current target. | Selects the nearest enemy as the current target. | ||
Line 18: | Line 19: | ||
---- | ---- | ||
;''Example'' | ;''Example'' | ||
TargetNearestEnemy(); | TargetNearestEnemy(); -- Targets nearest enemy. | ||
---- | ---- |
Revision as of 12:25, 16 December 2006
← WoW API < TargetNearestEnemy
This function is PROTECTED, and can only be called from Blizzard code.
|
Selects the nearest enemy as the current target.
TargetNearestEnemy([reverse]);
- Arguments
- ([reverse])
- reverse
- Boolean - Set to 1 or true to cycle backwards (optional).
- Returns
- nil
- Example
TargetNearestEnemy(); -- Targets nearest enemy.
- Description
- Selects the nearest enemy as the current target.
- This appears to be equivalent to pressing TAB, as it only cycles through enemies that you are facing, even if there are enemies behind you that are closer.
- This function only works if initiated by a hardware event.