View Single Post
05-25-09, 10:22 AM   #2
Akryn
A Firelord
AddOn Author - Click to view addons
Join Date: Mar 2008
Posts: 479
To reply to whispers, you need to set up an event handler for CHAT_MSG_WHISPER, see:
http://www.wowwiki.com/Events/Communication
http://www.wowwiki.com/Handling_events
and then to reply:
http://www.wowwiki.com/API_SendChatMessage

To send multiple whispers at a time is just a loop, strsubbing 254 characters and sending each iteration. See http://www.wowwiki.com/API_strsub . You could make it smarter and search for the nearest previous space too although that would be slightly more complicated. Note that if you have anything that's *really* long, don't send more than 9 chat messages without adding a delay between them or you'll DC yourself.
  Reply With Quote