androz2091 / easy-discord-commands Goto Github PK
View Code? Open in Web Editor NEWSimple framework to create commands using Discord.js
Home Page: https://npmjs.com/easy-discord-commands
Simple framework to create commands using Discord.js
Home Page: https://npmjs.com/easy-discord-commands
bot.client.on("ready",() => {
console.log("I'm ready")
})
(node:8348) UnhandledPromiseRejectionWarning: TypeError: Cannot read property 'on' of undefined
Comment on get les commandes avec leur nom et avoir leur props ?
It would be great to have some built-in commands such as help, eval etc.
Comment on fait pour exporter 'bot' ?
Exemple :
// index.js
const { Bot } = require('easy-discord-commands')
const bot = new Bot()
bot
.setToken("YOUR_DISCORD_BOT_TOKEN")
.setPrefix("!")
.showPrefixOnMention(true)
.connect();
// say.js
const { bot } = require('easy-discord-commands')
bot.addCommand("say", {
run: (message, args) => {
message.delete();
message.channel.send(args.join(" "));
},
aliases: [ "tell" ],
ownerOnly: true, // or use permissions, like below
permissions: [ "ADMINISTRATOR" ],
guildOnly: true // command can only be run on a server
});
Un truc du genre
Remplacer ça :
run: (message, args) => {
message.delete();
message.channel.send(args.join(" "));
},
aliases: [ "tell" ],
ownerOnly: true, // or use permissions, like below
permissions: [ "ADMINISTRATOR" ],
guildOnly: true // command can only be run on a server
});
par :
run: (message, args) => {
message.delete();
message.channel.send(args.join(" "));
},
config: {
aliases: [ "tell" ],
ownerOnly: true, // or use permissions, like below
permissions: [ "ADMINISTRATOR" ],
guildOnly: true // command can only be run on a server
}
});
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.