SHARE
TWEET

Untitled

a guest Aug 14th, 2016 93 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Threading;
  6. using IrcDotNet;
  7.  
  8. namespace Tim_s_IRC_bot
  9. {
  10.     class Program
  11.     {
  12.         static void Main(string[] args)
  13.         {
  14.             using (var client = new IrcDotNet.StandardIrcClient())
  15.          
  16.  
  17.             {
  18.                 using (var connectedEvent = new ManualResetEventSlim(false))
  19.                 {
  20.                     client.Connect("irc.freenode.net/7070", true, new IrcUserRegistrationInfo()
  21.                     {
  22.                         NickName = "testbot1234",
  23.                         Password = "Twanda01",
  24.                         UserName = "Tim241"
  25.                     });
  26.                     if (!connectedEvent.Wait(10000))
  27.                     {
  28.                         Console.WriteLine("Connection to '{0}' timed out.", "irc.freenode.net/6667");
  29.                         Console.ReadLine();
  30.                         return;
  31.                     }
  32.                
  33.                 client.Channels.Join("#google");
  34.  
  35.                     Console.ReadLine();
  36.                 };
  37.             };
  38.         }
  39.     }
  40. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top