From 5591562b0b23157b3ca8fb71509abe3eddded831 Mon Sep 17 00:00:00 2001 From: Dragon Fire Date: Fri, 30 Apr 2021 22:18:23 -0400 Subject: [PATCH] Fix --- commands/games-sp/anime-score.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/commands/games-sp/anime-score.js b/commands/games-sp/anime-score.js index 45d9c1c9..0edff234 100644 --- a/commands/games-sp/anime-score.js +++ b/commands/games-sp/anime-score.js @@ -76,7 +76,8 @@ module.exports = class AnimeScoreCommand extends Command { }); if (!msgs.size) return msg.reply(`Sorry, time is up! It was **${anime.averageScore}%**.`); const ans = Number.parseInt(msgs.first().content, 10); - if (Math.abs(ans - anime.averageScore) <= 10) return msg.reply(`Close! It was **${anime.averageScore}%**.`); + const close = Math.abs(ans - anime.averageScore); + if (close <= 10 && close !== 0) return msg.reply(`Close! It was **${anime.averageScore}%**.`); if (ans !== anime.averageScore) return msg.reply(`Nope, sorry, it was **${anime.averageScore}%**.`); return msg.reply(`Nice job! It was **${anime.averageScore}%**!`); } catch (err) {