Only no u half the time

This commit is contained in:
Dragon Fire
2021-05-02 09:35:20 -04:00
parent ca346c0ab8
commit fef444242b
3 changed files with 6 additions and 2 deletions
+2
View File
@@ -13,6 +13,8 @@ module.exports = class NoUCommand extends Command {
}
generateText() {
const chance = Boolean(Math.floor(Math.random() * 2));
if (chance) return null;
return 'no u';
}
};
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "xiao",
"version": "138.5.0",
"version": "139.0.0",
"description": "Your personal server companion.",
"main": "Xiao.js",
"private": true,
+3 -1
View File
@@ -10,7 +10,9 @@ module.exports = class AutoReplyCommand extends Command {
run(msg, args, fromPattern) {
if (msg.guild && !msg.channel.permissionsFor(this.client.user).has('SEND_MESSAGES')) return null;
return this.reply ? msg.reply(this.generateText(fromPattern)) : msg.say(this.generateText(fromPattern));
const text = this.generateText(fromPattern);
if (!text) return null;
return this.reply ? msg.reply(text) : msg.say(text);
}
generateText() {