3
0
mirror of https://github.com/reality/dbot.git synced 2024-12-24 19:52:36 +01:00
dbot/modules/puns.js
2011-08-22 22:17:13 +01:00

23 lines
636 B
JavaScript

var puns = function(dbot) {
var dbot = dbot;
return {
'listener': function(data) {
if(data.user == 'Lamp') {
dbot.say(data.channel, dbot.db.quoteArrs.lamp.random());
} else if(data.user == 'reality') {
dbot.instance.say(data.channel, dbot.db.realiPuns.random());
} else if(dbot.instance.inChannel(data.channel)) {
dbot.instance.say('aisbot', '.karma ' + data.user);
dbot.waitingForKarma = data.channel;
}
},
'on': 'JOIN'
};
}
exports.fetch = function(dbot) {
return puns(dbot);
};