Cooldown Twitch chatbot help me. Node.JS

Asked

Viewed 20 times

0

Talk personal, all right? I am trying to create a chatbox for my channel on Witch but I am going through some difficulties because I am a beginner in the subject. The bot is functional but if someone spams the commands in the chat becomes a mess then I would like to put cooldown in the commands.. I tried some solutions I found in uncle google but as a beginner it is possible that I have implemented the wrong way and ended up not working. the code would be as follows:

client.on("chat", function (channel, user, message, self){
if(message === "!fb"){
    client.action("picolinotv", "https://fb.com/PicolinoTV");
}

if(message === "Olá"){
    client.action("picolinotv", "@" + user["display-name"] + " seja bem vindo!");
}
No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.