WoW:Focus target

From AddOn Studio
Revision as of 04:14, 17 October 2007 by WoWWiki>Piumosso-Uldum (new page)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

A focus target is a secondary target system, used to keep track of a second unit other than the currently targeted unit. The focus is a sort of "target memory" meaning that the focus can be set then recalled with simple macro commands. Furthermore, the user interface supplies full real-time updates for the currently stored focus, including health and mana updates and enemy casting bars. Some user interface addons provide a complete unit frame for the focus.

Note that actions cannot be performed directly on the focus. A player must first acquire the focus as the current target, usually with a macro. The function is very useful for healing classes and crowd control classes that need to keep track of a player or mob while casting spells on someone else.

Using focus targets

Focusing is usually done through macros. To set a mob or player as the focus, first target it then type the command /focus into the chat window. To re-acquire the focus as the current target, use the command /target focus. To clear the focus, use the command /clearfocus. In the default user interface, the target unit frame will be highlighted in white if it is also the focus.

Focus works as a generic unit name in macros, similar to "player", "target", or "pet". This means it can be passed to UI functions that take a unit name, or used in modifiers in macros. For example /cast [target=focus] Polymorph would attempt to cast Polymorph on whatever the stored target is. A mage using this macro simply has to set his focus to the mob he wants to sheep, and can re-sheep with one button without having to manually click the mob again.

Focus Command Summary
Slash command Function
/focus Set the current target as the focus
/clearfocus Clear the current focus
/target focus Target the focus
/target focustarget Target whatever the focus is targeting1
/cast [target=focus] ... Targeting the focus as a modifier of another spell2
/script SetRaidTarget("focus", 1) Set a raid icon on the focus3
  1. Target of target can be chained further. (e.g. /target focustargettargettarget)
  2. Also works with /use or any other command that takes modifiers in square brackets.
  3. Focus is passed to all UI functions that take a unit name as "focus".

See also