View Single Post
12-20-12, 11:25 PM
Join Date: Mar 2006
If you just want to check if they're in your group, you can use any UnitWhatever function; all of those functions will return
if called with a name (instead of a unitID) that doesn't belong to someone in your group. eg. this will work the same way:
if destGUID == UnitGUID("player") or UnitClass(name) then -- code end
Also, looking up UnitGUID("player") on every combat log is extremely inefficient. Look it up
when PLAYER_LOGIN fires (you're probably already doing other initialization stuff there) and store it in a file-level local variable, and compare the destGUID against that.
Troubleshoot an addon
Turn any code into an addon
More addon resources
Need help with your code?
code! Attach or
Please don’t PM me
about addon bugs or code questions. Post a comment or forum thread instead!
View Public Profile
Send a private message to Phanx
Find More Posts by Phanx