API UnitIsUnit
Talk0
98,518pages on
this wiki
this wiki
Revision as of 19:51, December 23, 2006 by Starlightblunder (Talk | contribs)
Returns true if the two specified units are the same, false otherwise.
isSame = UnitIsUnit(unit1, unit2);
Parameters
Arguments
Returns
- isSame
- Boolean - 1 if the two units are the same entity, nil otherwise.
Example
if ( UnitIsUnit("targettarget", "player") ) then
message("Look at me, I have aggro from " .. UnitName("target") .. "!");
end;
Result
Displays a message if your target is targetting you.