aboutsummaryrefslogtreecommitdiff
path: root/bot.js
diff options
context:
space:
mode:
authorMinteck <contact@minteck.org>2022-02-10 22:40:42 +0100
committerMinteck <contact@minteck.org>2022-02-10 22:40:42 +0100
commit5dd6d046e166a52e73b68b7e6015553231f333a3 (patch)
tree3faa1926a09b15a206630b5be8c3ab06f790cbd3 /bot.js
parent8891b6213d1b691cc8c5a0c35abd87ebe6c9f6b7 (diff)
downloadponyfind-5dd6d046e166a52e73b68b7e6015553231f333a3.tar.gz
ponyfind-5dd6d046e166a52e73b68b7e6015553231f333a3.tar.bz2
ponyfind-5dd6d046e166a52e73b68b7e6015553231f333a3.zip
Feature: implements #1
Diffstat (limited to 'bot.js')
-rw-r--r--bot.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/bot.js b/bot.js
index 2cdcce8..20da490 100644
--- a/bot.js
+++ b/bot.js
@@ -44,6 +44,7 @@ global.l = (en, fr, id, gid) => {
}
const commands = require('./modules/registers');
+const getHelp = require("./modules/help");
client.on('ready', async () => {
client.user.setActivity("/help", { type: "LISTENING" })
@@ -58,6 +59,12 @@ client.on('ready', async () => {
console.log("Successfully reloaded application (/) commands globally");
});
+client.on('message', message => {
+ if (message.content.trim() === "<@" + client.user.id + ">") {
+ message.reply(getHelp(message.guild, message.guild.id, message.author.id, true));
+ }
+})
+
client.on('interactionCreate', async interaction => {
if (!interaction) { return; }