Hi I’ve been working on a bot and wanted to make a cooldown for the user for 10 mins if they use the command again I created this system that works as a cooldown but for all users how would I make it for only the user of the command and have it be individual.
if(message == '!joinqueue') {
if(!block) {
client.say(channel, `@${user.username}, Joined The Queue!`);
queue.push(`${user.username}`);
console.log(queue);
block = true
setTimeout(() => {
block = false;
}, (60 * 10000))
}
else {
client.say(channel, `@${user.username} Please Wait Before Doing This Command Again`)
}