WoW API: SetRaidTargetIcon

From AddOn Studio
Revision as of 04:47, 15 August 2023 by Move page script (talk | contribs) (Move page script moved page API SetRaidTargetIcon to API SetRaidTargetIcon without leaving a redirect)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

WoW API < SetRaidTargetIcon

"I" iconThis function is implemented in Lua here FrameXML/TargetFrame.lua.

Sets or clears a Raidicon on top of a unit.

SetRaidTargetIcon("unit", index)

Arguments[edit]

unit
String - UnitID, e.g. "target"
index
Integer - Raid icon index; 0 to remove any icons from the unit.
1 = Yellow 4-point Star
2 = Orange Circle
3 = Purple Diamond
4 = Green Triangle
5 = White Crescent Moon
6 = Blue Square
7 = Red "X" Cross
8 = White Skull

Notes[edit]

  • Patch 1.11 introduced RaidIcons for easier targetting. This function sets an icon on top of a targets head.
  • Setting the same icon twice to the same target will drop the icon.
  • SetRaidTarget is the native API function used (and does not exhibit the toggling behavior); see also GetRaidTargetIndex.