Bots can't reply

This commit is contained in:
Dragon Fire
2019-11-11 23:08:06 -05:00
parent 86a77ffcaf
commit b79fb4ffcc
+2
View File
@@ -26,12 +26,14 @@ module.exports = class RussianRouletteCommand extends Command {
if (current) return msg.reply(`Please wait until the current game of \`${current.name}\` is finished.`); if (current) return msg.reply(`Please wait until the current game of \`${current.name}\` is finished.`);
this.client.games.set(msg.channel.id, { name: this.name }); this.client.games.set(msg.channel.id, { name: this.name });
try { try {
if (!opponent.bot) {
await msg.say(`${opponent}, do you accept this challenge?`); await msg.say(`${opponent}, do you accept this challenge?`);
const verification = await verify(msg.channel, opponent); const verification = await verify(msg.channel, opponent);
if (!verification) { if (!verification) {
this.client.games.delete(msg.channel.id); this.client.games.delete(msg.channel.id);
return msg.say('Looks like they declined...'); return msg.say('Looks like they declined...');
} }
}
let userTurn = true; let userTurn = true;
const gun = shuffle([true, false, false, false, false, false, false, false]); const gun = shuffle([true, false, false, false, false, false, false, false]);
let round = 0; let round = 0;