diff options
Diffstat (limited to 'echo-bot/index.js')
-rw-r--r-- | echo-bot/index.js | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/echo-bot/index.js b/echo-bot/index.js new file mode 100644 index 0000000..8c932a8 --- /dev/null +++ b/echo-bot/index.js @@ -0,0 +1,22 @@ +require('tinycolor'); +var irc = function() { + var Proxy = require('../node_modules/dynobot/proxy'); + var Channel = require('../node_modules/dynobot/channel'); + var IrcClient = require('../irc-client.js').IrcClient; + + var channel = new Channel(); + return new Proxy(IrcClient.prototype, 'irc', channel); +}(); + +irc.on('privmsg', function(nick, channel, message) { +// console.log('privmsg: ', arguments); + irc.notice(channel, nick + ': ' + message); +}); + +irc.join('#bitraf2', function() { + console.log('joined channel!'.green); +}); + +console.log("echo bot started".green); + +// process.exit(0); |