Thread: Get Group Rolls
View Single Post
12-14-09, 06:07 PM   #2
Akryn
A Firelord
AddOn Author - Click to view addons
Join Date: Mar 2008
Posts: 479
I should point out that I've never done this. There are mods out there that do do it and they are probably a good place to look. It appears though that the event is "CHAT_MSG_LOOT" and its arg1 is the whole chat message, parse it with e.g.

Code:
local name, roll, item
name, roll, item = arg1:match((LOOT_ROLL_ROLLED:gsub("%d","%s")):format("(.+)","(.+)",".+",".+",".+",".+","(.+)",".+"))
if not name then
     name = UnitName("player")
     roll, item = arg1:match((LOOT_ROLL_ROLLED_SELF:gsub("%d","%s")):format("(.+)",".+",".+",".+",".+","(.+)",".+"))
end
if not roll then return end
(YMMV, that code is *very* untested )

Last edited by Akryn : 12-14-09 at 06:09 PM.
  Reply With Quote