Created
May 6, 2013 19:52
-
-
Save dz0ny/5527663 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
odgovori_spam_prot = (r, msg)-> | |
redis.get("irc:antispam").then (anti)-> | |
unless anti | |
redis.set "irc:antispam", msg | |
redis.expireat "irc:antispam", moment().add("hours", 1).unix() | |
r.reply msg | |
bot.command /^jutro$/i, (r) -> | |
odgovori_spam_prot r, "Jutro #{r.nick} !" | |
bot.command /^dan$/i, (r) -> | |
odgovori_spam_prot r, "Dan #{r.nick} !" | |
bot.command /^caw$/i, (r) -> | |
odgovori_spam_prot r, "Adijo #{r.nick}" | |
bot.command /^ju+hu+$/i, (r) -> | |
odgovori_spam_prot r, "Lepo te je slišati #{r.nick}" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment