@Joe_Stead:

Looking forward to a day it nothing tomorrow

Joe Stead
Tag Archives: bot
Creating an IRC bot in C#

Creating an IRC bot with some basic functionality may seem like a scary thought, you have to connect to connect to the server, join channels, and respond to commands. It isn’t as bad as you may think, once you learn the basics of the IRC protocol and some the basics of socket programming in C#, in fact it actually becomes extremely simple.

In this tutorial it will be a fairly static bot which responds to commands such as “!say message”, “!join #channel”, “!part”, and “!quit”. Anybody will be able to send these commands and the bot will respond regardless of who sends them. If you wish to add aditional security it is up to you to add that functionality in.

I will be using Visual Studio 2008 in this tutorial to complete the code, if you are a student you can receive a copy free from Microsoft Dreamspark or you can download Microsoft Visual C# Express Edition for free, both of which will work fine for this task.