Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const {Discord,RichEmbed} = require('discord.js');
- const {prefix,token,classic_roles} = require('../config.json');
- const logs = require('../logs/logs');
- module.exports.run = async (bot, message, args) => {
- var list_groups = [];
- var name = [];
- var dscription = [];
- var access = [];
- var groups = [];
- bot.commands.forEach((f,i) => {
- if (!list_groups.includes(f.help.groups)) {
- list_groups.push(f.help.groups)
- }
- name.push(f.help.name)
- dscription.push(f.help.description)
- access.push(f.help.access)
- groups.push(f.help.groups)
- });
- let i = 0;
- const embed = new RichEmbed()
- if (args.length < 1 ) {
- embed.setColor('#5B4DCA');
- while (i < list_groups.length) {
- let x = 0;
- embed.setTitle(`${list_groups[i]}`)
- while (x < groups.length) {
- if (groups[x] === list_groups[i]) {
- embed.addField('test1','test2')
- }
- x++;
- }
- message.channel.send(embed)
- i++;
- }
- }
- }
- logs.logs('commands','!help',message.author);
- }
- module.exports.help = {
- name: "help",
- description: "Vous permet d'obtenir toutes les commandes accessibles pour vos rôles.",
- access: "Public",
- groups: "Outils"
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement