Thread: Is Npc Dead
View Single Post
04/17/14, 08:46 AM   #3
Sharlikran
 
Sharlikran's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 672
Originally Posted by Iyanga View Post
I suspect that unitTag is the unitName, just that unitTag _also_ accepts symbolic string names for certain cases, like the general "player" string.

My first try would be:
GetUnitReaction(GetUnitNameHighlightedByReticle())

My second try to filter it through GetRawUnitName():
GetUnitReaction(GetRawUnitName(GetUnitNameHighlightedByReticle()))

If this doesn't work, well, at least we can then negate the assumption.
I had wondered how to access UNIT_REACTION_DEAD. I searched the API page, and I just didn't see what to use. Which is why I thought IsUnitDead(unittag) was correct. Then you post GetUnitReaction(unittag) and I was like, what? I didn't see that. GetUnitReaction(UNIT_REACTION_DEAD) works perfectly.
  Reply With Quote