示例#1
0
 public void joinChannel(string channel, IRCListener listener)
 {
     channel = channel.ToLower();
     registerListener(channel, listener);
     if (!joinedChannels.ContainsKey(channel))
     {
         joinedChannels.Add(channel, 1);
         IRCJoinCommand.send(this, channel);
     }
     else
     {
         joinedChannels[channel]++;
     }
 }
示例#2
0
 private void doConnect()
 {
     // Socket Connected - DO LOGIN
     oAuth.clearToken();
     IRCCapCommand.send(this, ":twitch.tv/tags");
     IRCPassCommand.send(this, oAuth);
     IRCNickCommand.send(this, Nickname);
     IRCUserCommand.send(this, Nickname, RealName);
     ReadMessage();
     foreach (KeyValuePair <string, int> item in joinedChannels)
     {
         string channel = item.Key;
         IRCJoinCommand.send(this, channel);
     }
 }