Example #1
0
  public IRCMsgHandler(IRCBot bot) {

    this.bot = bot;

    botnick = bot.getConfigs().getBotnick();
    startchan = bot.getConfigs().getStartChan();

    this.inboundMsgQ = bot.getInboundMsgQ();
    this.outboundMsgQ = bot.getOutboundMsgQ();

    loadServerResponseCodesToIgnore();

    ircCommands = bot.getIrcCommands();

    this.setInterruptListeners(bot.getInterruptListeners());
    this.setEventListeners(bot.getEventListeners());
    this.botCommandListeners = bot.getBotCommandListeners();

    pipelines = new Pipelines();

    setThreadExecuting(true);

    if (bot.getConfigs().isHeadless()) {
      UserInputBox uib = new UserInputBox(outboundMsgQ);
      uib.stub();
    }
  }