示例#1
0
文件: Program.cs 项目: MrTiggr/Murphy
 static void Main(string[] args)
 {
     bot = new Bot();
     bot.OnRawMessage+=new IrcEventHandler(bot_OnRawMessage);
     bot.ConnectAll();
     new Thread(new ThreadStart(ReadCommand)).Start();
 }
示例#2
0
文件: Service.cs 项目: MrTiggr/Murphy
 protected override void OnStart(string[] args)
 {
     bot = new Bot();
     bot.ConnectAll();
 }
示例#3
0
文件: Plugin.cs 项目: MrTiggr/Murphy
 public Plugin(Bot bot)
 {
     this.bot = bot;
 }
示例#4
0
 public Reputation(Bot bot)
     : base(bot)
 {
     BOT_CONTROL_SEQ = Bot.Configuration["Config"].Attributes["ControlSeq"].Value;
     enc=new RijndaelEnhanced(K3Y, IV, 256, 512, 256, "SHA-1", S4LT, 5);
     //Hook Up the Bot event Handlers
     Bot.OnChannelMessage += new IrcEventHandler(Bot_OnChannelMessage);
     Bot.OnQueryMessage += new IrcEventHandler(Bot_OnPrivateMessage);
 }
示例#5
0
文件: Program.cs 项目: MrTiggr/Murphy
 static void Main()
 {
     bot = new Bot();
     Application.Run(new frmMain());
 }
示例#6
0
文件: frmMain.cs 项目: MrTiggr/Murphy
        private void frmMain_Load(object sender, EventArgs e)
        {
            writer = new System.IO.StringWriter();
            Console.SetOut(writer);

            Application.ApplicationExit += new EventHandler(Application_ApplicationExit);
            FormClosing += new FormClosingEventHandler(frmMain_FormClosing);
            txtLog.TextChanged += new EventHandler(txtLog_TextChanged);
            txtMessage.KeyDown += new KeyEventHandler(txtMessage_KeyDown);

            bot = new Bot();
            bot.OnRawMessage+=new IrcEventHandler(Bot_OnRawMessage);

            bot.ConnectAll();

            thread = new System.Threading.Thread(new System.Threading.ThreadStart(Log));
            thread.Start();
        }