WoW:API UnitIsUnit: Difference between revisions
Jump to navigation
Jump to search
({{wowapi}}, format, example) |
m (Move page script moved page API UnitIsUnit to API UnitIsUnit without leaving a redirect) |
(No difference)
|
Latest revision as of 04:47, 15 August 2023
← WoW API < UnitIsUnit
Returns true if the two specified units are the same, false otherwise.
isSame = UnitIsUnit(unit1, unit2);
Parameters[edit]
Arguments[edit]
Returns[edit]
- isSame
- Boolean - 1 if the two units are the same entity, nil otherwise.
Example[edit]
if ( UnitIsUnit("targettarget", "player") ) then message("Look at me, I have aggro from " .. UnitName("target") .. "!"); end;
Result[edit]
Displays a message if your target is targetting you.