3.1.5 • Published 3 years ago

easy-djs-handler v3.1.5

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

Module to make an fast setup Discord Bot, simply do:

example

main file

const djs = require('easy-djs-handler');
const discordJS = require('discord.js');
const client = new discordJS.Client();
new djs.handler(client, {
	commands: './commands',
	events: './events',
	commandTable: true,
})
	.setPrefix(['renata')
	//.setDefaultCooldown(3)
	.setOwners(['id1','id2'])
	.setTeam([])

client.login('token');

folder structure

commands/general/dir/dir2/dir3/ping.js

commands/ping.js

example

commands/pings.js

module.exports = {
	name: 'ping',
	aliases: ['p'],
	cooldown: 10, // seconds
	reqArgs: 0,
    guildOnly: true,
	usage: 'example',
	nsfw: false,
	ownerOnly: false,
	teamOnly: false,
	userPerms: ['ADMINISTRATOR', 'more', 'more'],
	botPerms: ['ADMINISTRATOR'],
	reqRole: 'role name',
	execute({ message, args, handler, client }) {
		message.channel.send('pong');
	},
};

folder structure

events/message.js

events/message/dir/dir2/dir3/message.js

example

events/ready.js

module.exports = (client, handler) => {
	console.log(`${client.user.tag} olarak girş başarıyla yapıldı`);
};

events/message.js

module.exports = (client, handler, message) => {
	console.log("gördm amk");
};

Features

Example

features/test.js

module.exports = (client, handler) => {
	client.on('message', (message) => {
		console.log(message.content);
	});

	client.on('ready', () => {
		console.log('ready');
	});
};
3.1.5

3 years ago

3.1.3

3 years ago

3.1.2

3 years ago

3.1.4

3 years ago

3.1.1

3 years ago

3.1.0

3 years ago

3.0.0

3 years ago

2.1.3

3 years ago

2.1.2

3 years ago

2.1.1

3 years ago

2.1.0

3 years ago

2.0.0

3 years ago

1.0.0

3 years ago