Esempio n. 1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="IRC"/> class.
        /// </summary>
        /// <param name="nick">Bot Nickname</param>
        /// <param name="realname">Realname</param>
        /// <param name="username">Username</param>
        /// <param name="server">Irc Host Address</param>
        /// <param name="port">Port</param>
        /// <param name="lastknown">Last known IRC Reply Code</param>
        /// <param name="colour">Console Color</param>
        /// <param name="channel">Starting channel</param>
        /// <param name="key">Starting channel's Key</param>
        /// <param name="owner">Bot Owner</param>
        /// <param name="debug">Debug Channel</param>
        public Irc(string nick, string realname, string username, string nickPass, string server, string serverPassword, int port, ReplyCode lastknown, ConsoleColor colour, string channel, string key = "", string owner = "", string debug = "", string debkey = "")
        {
            settings = new Settings( );

            this.nick     = nick;
            this.realname = realname;
            this.username = username;
            this.host     = server;
            this.port     = port;
            this.code     = lastknown;
            this.colour   = colour;
            this.__nspass = nickPass;
            this._srvPass = serverPassword;
            _owner        = owner;
            _dbgchan      = debug;
            _dbkey        = debkey;
            channelBuffer = new Stack <ChannelData> ( );
            if (!string.IsNullOrEmpty(channel))
            {
                startchan = channel;
            }
            if (!string.IsNullOrEmpty(key))
            {
                startkey = key;
            }

            songman = new LastFMSongManager( );
            //songman.Listen ( );
        }
Esempio n. 2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="IRC"/> class.
        /// </summary>
        /// <param name="nick">Bot Nickname</param>
        /// <param name="realname">Realname</param>
        /// <param name="username">Username</param>
        /// <param name="server">Irc Host Address</param>
        /// <param name="port">Port</param>
        /// <param name="lastknown">Last known IRC Reply Code</param>
        /// <param name="colour">Console Color</param>
        /// <param name="channel">Starting channel</param>
        /// <param name="key">Starting channel's Key</param>
        /// <param name="owner">Bot Owner</param>
        /// <param name="debug">Debug Channel</param>
        public Irc( string nick, string realname, string username, string nickPass, string server, string serverPassword, int port, ReplyCode lastknown, ConsoleColor colour, string channel, string key = "", string owner = "", string debug = "", string debkey = "" )
        {
            settings = new Settings ( );

            this.nick = nick;
            this.realname = realname;
            this.username = username;
            this.host = server;
            this.port = port;
            this.code = lastknown;
            this.colour = colour;
            this.__nspass = nickPass;
            this._srvPass = serverPassword;
            _owner = owner;
            _dbgchan = debug;
            _dbkey = debkey;
            channelBuffer = new Stack<ChannelData> ( );
            if ( !string.IsNullOrEmpty ( channel ) ) startchan = channel;
            if ( !string.IsNullOrEmpty ( key ) ) startkey = key;

            songman = new LastFMSongManager ( );
            //songman.Listen ( );
        }