I'm trying to write a simple addon for my Guild which lists all online guild members and all members of a chat channel.
This is to be used to record DKP. (We award DKP to all online players.)
I have the guild enumeration all sweet but I'm having trouble enumerating the members of a chat channel.
This can be achieved in game by typing /chatlist # or /chatwho # where "#" = the channel number or channel name.
I posted on the official WoW forums (UI section) but I cant seem to work out how to use the information I was given correctly:
hello, sorry I was not very clear. Here is what you need to do:
(1) Register the event CHAT_MSG_CHANNEL_LIST
(2) Issue ListChannelByName
Your On_event code look something like:
if(event == "CHAT_MSG_CHANNEL_LIST") then
WHO_CHANNEL_USERS(arg1);
end
...
...
..
function WHO_CHANNEL_USERS(msg)
print (msg)
end
|
Basically I want to find all members of the channel "Standby5D" and add them to an edit box (or an array). (For simplicties sake a simple DEFAULT_CHAT_FRAME:AddMessage(this_is_a_stub) in place of this in any examples would be sufficiant. Once I RETRIEVE the string of names I'm set.
)
I was wondering if someone could point me in the right direction. I've been looking at other UI addons I use; the Register Event section in particular but I dont understand the link between registering the event and then calling ListChannelByName.
Any help would be greatly appreciated.