This commit is contained in:
2025-08-07 23:35:29 +02:00
parent 5381bed30a
commit 805fc266d5
11 changed files with 961 additions and 398 deletions

38
commands/help.js Normal file
View File

@ -0,0 +1,38 @@
const { EmbedBuilder } = require("discord.js");
exports.name = "help";
exports.description =
":scroll: Shows this message. (this bot is a crude imitation of tbolt's better bot :P)";
exports.usage = "<<help [optional other command]";
exports.example = "<<help res";
exports.run = (client, message, args) => {
let embed = new EmbedBuilder();
embed.setTitle("Commands Helper");
if (args[0]) {
const cmd = client.commands.get(args[0]);
if (!cmd)
return message.channel.send(
"Command not found, try `<<help` first."
);
embed.setTitle(`Help for \`${cmd.name}\` command`);
embed.setDescription(cmd.description);
embed.addFields(
{
name: "Usage",
value: cmd.usage,
},
{
name: "Example",
value: cmd.example,
}
);
} else {
client.commands.forEach((cmd) => {
embed.addFields({
name: cmd.name,
value: cmd.description,
});
});
}
embed.setColor(0x00ff00);
message.channel.send({ embeds: [embed] });
};