View Single Post
11-16-17, 12:15 AM   #4
Joker119
A Flamescale Wyrmkin
 
Joker119's Avatar
AddOn Author - Click to view addons
Join Date: Aug 2014
Posts: 113
So I've got the event working, and it send emotes to the error frame like it should, but i'm having issues filtering out ones targeting the player.
According to WoWprogramming CHAT_MSG_TEXT_EMOTE contains message, sender, language, channelstring, target ... but target returns a nil value no matter what emote is used.

lua Code:
  1. local function scrollingEmotes(self, event, message, sender, language, channelstring, target, ...)
  2.     if event == "CHAT_MSG_EMOTE" or event == "CHAT_MSG_TEXT_EMOTE" then
  3.                         --debugging, print the message sender and target to chatframe
  4.             print(message, sender, target)
  5.             message = "|cffff4500"..(message).."|r"
  6.             UIErrorsFrame:AddMessage(message)
  7.             print("reeee")
  8.     end
  9. end

the print() should be giving me the emote message, the character sending it and the target, but that 'target' is always empty.
__________________
My Addons | "If someone says something is impossible, they lack either imagination, or determination."
  Reply With Quote