✨ Bug fixes & update (v3.0.0)
This commit is contained in:
@@ -57,23 +57,24 @@ All you have to do is turn on your bot !
|
|||||||
play <name>, play music in a voice channel.
|
play <name>, play music in a voice channel.
|
||||||
pause, pause the current music.
|
pause, pause the current music.
|
||||||
resume, puts the current music back on.
|
resume, puts the current music back on.
|
||||||
queue, see the next musics.
|
queue, see the next songs.
|
||||||
clear-queue, delete the next music.
|
clear-queue, delete the next music.
|
||||||
shuffle, to mix the queue.
|
shuffle, to mix the queue.
|
||||||
np, see music in progress.
|
nowplaying, see music in progress.
|
||||||
loop, to enable or disable the repeat function.
|
loop, to enable or disable the repeat function.
|
||||||
volume <1 - 100>, change the volume.
|
volume <1 - 100>, change the volume.
|
||||||
skip, skip to next music.
|
skip, skip to next music.
|
||||||
stop, stop all music.
|
stop, stop all music.
|
||||||
filter <filter>, add / remove filters.
|
filter <filter>, add / remove filter.
|
||||||
w-filters, see filters.
|
w-filters, see filters.
|
||||||
```
|
```
|
||||||
|
|
||||||
### 💡 General commands
|
### 💡 General commands
|
||||||
|
|
||||||
```
|
```
|
||||||
help, see the list of available orders.
|
|
||||||
ping, see the bot latency.
|
ping, see the bot latency.
|
||||||
|
help, see the list of available commands.
|
||||||
|
debug, see number of voice connections.
|
||||||
```
|
```
|
||||||
|
|
||||||
### 🏓 Utilities (to change the code)
|
### 🏓 Utilities (to change the code)
|
||||||
|
|||||||
@@ -1,11 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
|
||||||
|
|
||||||
client.player.clearQueue(message);
|
|
||||||
|
|
||||||
message.channel.send(`${client.emotes.success} - The queue has just been **removed** !`);
|
|
||||||
|
|
||||||
};
|
|
||||||
48
commands/core/help.js
Normal file
48
commands/core/help.js
Normal file
@@ -0,0 +1,48 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'help',
|
||||||
|
aliases: ['h'],
|
||||||
|
category: 'Core',
|
||||||
|
utilisation: '{prefix}help <command name>',
|
||||||
|
|
||||||
|
execute(client, message, args) {
|
||||||
|
if (!args[0]) {
|
||||||
|
const infos = message.client.commands.filter(c => c.category == 'Infos').map((c) => '`' + c.name + '`').join(', ');
|
||||||
|
const music = message.client.commands.filter(c => c.category == 'Music').map((c) => '`' + c.name + '`').join(', ');
|
||||||
|
|
||||||
|
message.channel.send({
|
||||||
|
embed: {
|
||||||
|
color: 'ORANGE',
|
||||||
|
author: { name: 'Help pannel' },
|
||||||
|
footer: { text: 'This bot uses a Github project made by Zerio (ZerioDev/Music-bot)' },
|
||||||
|
fields: [
|
||||||
|
{ name: 'Bot', value: infos },
|
||||||
|
{ name: 'Music', value: music },
|
||||||
|
{ name: 'Filters', value: '`bassboost`, `8D`, `vaporwave`, `nightcore`, `phaser`, `tremolo`, `vibrato`, `reverse`, `treble`, `normalizer`, `surrounding`, `pulsator`, `subboost`, `karaoke`, `flanger`, `gate`, `haas`, `mcompand`' },
|
||||||
|
],
|
||||||
|
timestamp: new Date(),
|
||||||
|
description: `To use filters, ${client.config.prefix}filter (the filter). Example : ${client.config.prefix}filter 8D.`,
|
||||||
|
},
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
const command = message.client.commands.get(args.join(" ").toLowerCase()) || message.client.commands.find(c => c.aliases && c.aliases.includes(args.join(" ").toLowerCase()));
|
||||||
|
|
||||||
|
if (!command) return message.channel.send(`${client.emotes.error} - I did not find this command !`);
|
||||||
|
|
||||||
|
message.channel.send({
|
||||||
|
embed: {
|
||||||
|
color: 'ORANGE',
|
||||||
|
author: { name: 'Help pannel' },
|
||||||
|
footer: { text: 'This bot uses a Github project made by Zerio (ZerioDev/Music-bot)' },
|
||||||
|
fields: [
|
||||||
|
{ name: 'Name', value: command.name, inline: true },
|
||||||
|
{ name: 'Category', value: command.category, inline: true },
|
||||||
|
{ name: 'Aliase(s)', value: command.aliases.length < 1 ? 'None' : command.aliases.join('\n'), inline: true },
|
||||||
|
{ name: 'Utilisation', value: command.utilisation.replace('{prefix}', client.config.prefix), inline: true },
|
||||||
|
],
|
||||||
|
timestamp: new Date(),
|
||||||
|
description: 'Find information on the command provided.\nMandatory arguments `[]`, optional arguments `<>`.',
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
},
|
||||||
|
};
|
||||||
@@ -1,23 +0,0 @@
|
|||||||
exports.run = async (client, message, args) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
|
||||||
|
|
||||||
if (!args[0]) return message.channel.send(`${client.emotes.error} - Please specify a valid filter to enable or disable !`);
|
|
||||||
|
|
||||||
const filterToUpdate = Object.values(client.filters).find((f) => f.toLowerCase() === args[0].toLowerCase());
|
|
||||||
|
|
||||||
if (!filterToUpdate) return message.channel.send(`${client.emotes.error} - This filter doesn't exist !`);
|
|
||||||
|
|
||||||
const filterRealName = Object.keys(client.filters).find((f) => client.filters[f] === filterToUpdate);
|
|
||||||
|
|
||||||
const queueFilters = client.player.getQueue(message).filters
|
|
||||||
const filtersUpdated = {};
|
|
||||||
filtersUpdated[filterRealName] = queueFilters[filterRealName] ? false : true;
|
|
||||||
client.player.setFilters(message, filtersUpdated);
|
|
||||||
|
|
||||||
if (filtersUpdated[filterRealName]) message.channel.send(`${client.emotes.music} - I'm **adding** the filter to the music, please wait... Note : the longer the music is, the longer this will take.`);
|
|
||||||
else message.channel.send(`${client.emotes.music} - I'm **disabling** the filter on the music, please wait... Note : the longer the music is playing, the longer this will take.`);
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,18 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
message.channel.send({
|
|
||||||
embed: {
|
|
||||||
color: 'ORANGE',
|
|
||||||
author: { name: 'Help pannel' },
|
|
||||||
footer: { text: 'This bot uses a Github project made by Zerio (ZerioDev/Music-bot)' },
|
|
||||||
fields: [
|
|
||||||
{ name: 'Bot', value: '`ping`' },
|
|
||||||
{ name: 'Music', value: '`play`, `pause`, `resume`, `queue`, `clear-queue`, `shuffle`, `np`, `loop`, `volume`, `skip`, `stop`, `filter`, `w-filters`' },
|
|
||||||
{ name: 'Filters', value: '`bassboost`, `8D`, `vaporwave`, `nightcore`, `phaser`, `tremolo`, `vibrato`, `reverse`, `treble`, `normalizer`, `surrounding`, `pulsator`, `subboost`, `karaoke`, `flanger`, `gate`, `haas`, `mcompand`' },
|
|
||||||
],
|
|
||||||
timestamp: new Date(),
|
|
||||||
description: `To use filters, ${client.config.prefix}filter (the filter). Example : ${client.config.prefix}filter 8D.`,
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
};
|
|
||||||
10
commands/infos/debug.js
Normal file
10
commands/infos/debug.js
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'debug',
|
||||||
|
aliases: [],
|
||||||
|
category: 'Infos',
|
||||||
|
utilisation: '{prefix}debug',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
message.channel.send(`${client.emotes.success} - Robot connected in **${client.voice.connections.size}** channels !`);
|
||||||
|
},
|
||||||
|
};
|
||||||
10
commands/infos/ping.js
Normal file
10
commands/infos/ping.js
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'ping',
|
||||||
|
aliases: [],
|
||||||
|
category: 'Infos',
|
||||||
|
utilisation: '{prefix}ping',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
message.channel.send(`${client.emotes.success} - Ping : **${client.ws.ping}ms** !`);
|
||||||
|
},
|
||||||
|
};
|
||||||
@@ -1,17 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
|
||||||
|
|
||||||
const repeatMode = client.player.getQueue(message).repeatMode;
|
|
||||||
|
|
||||||
if (repeatMode) {
|
|
||||||
client.player.setRepeatMode(message, false);
|
|
||||||
return message.channel.send(`${client.emotes.success} - Repeat mode **disabled** !`);
|
|
||||||
} else {
|
|
||||||
client.player.setRepeatMode(message, true);
|
|
||||||
return message.channel.send(`${client.emotes.success} - Repeat mode **enabled** !`);
|
|
||||||
};
|
|
||||||
|
|
||||||
};
|
|
||||||
16
commands/music/clear-queue.js
Normal file
16
commands/music/clear-queue.js
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'clear-queue',
|
||||||
|
aliases: ['cq'],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}clear-queue',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
||||||
|
|
||||||
|
client.player.clearQueue(message);
|
||||||
|
|
||||||
|
message.channel.send(`${client.emotes.success} - The queue has just been **removed** !`);
|
||||||
|
},
|
||||||
|
};
|
||||||
28
commands/music/filter.js
Normal file
28
commands/music/filter.js
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'filter',
|
||||||
|
aliases: [],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}filter [filter name]',
|
||||||
|
|
||||||
|
execute(client, message, args) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
||||||
|
|
||||||
|
if (!args[0]) return message.channel.send(`${client.emotes.error} - Please specify a valid filter to enable or disable !`);
|
||||||
|
|
||||||
|
const filterToUpdate = Object.values(client.filters).find((f) => f.toLowerCase() === args[0].toLowerCase());
|
||||||
|
|
||||||
|
if (!filterToUpdate) return message.channel.send(`${client.emotes.error} - This filter doesn't exist !`);
|
||||||
|
|
||||||
|
const filterRealName = Object.keys(client.filters).find((f) => client.filters[f] === filterToUpdate);
|
||||||
|
|
||||||
|
const queueFilters = client.player.getQueue(message).filters;
|
||||||
|
const filtersUpdated = {};
|
||||||
|
filtersUpdated[filterRealName] = queueFilters[filterRealName] ? false : true;
|
||||||
|
client.player.setFilters(message, filtersUpdated);
|
||||||
|
|
||||||
|
if (filtersUpdated[filterRealName]) message.channel.send(`${client.emotes.music} - I'm **adding** the filter to the music, please wait... Note : the longer the music is, the longer this will take.`);
|
||||||
|
else message.channel.send(`${client.emotes.music} - I'm **disabling** the filter on the music, please wait... Note : the longer the music is playing, the longer this will take.`);
|
||||||
|
},
|
||||||
|
};
|
||||||
20
commands/music/loop.js
Normal file
20
commands/music/loop.js
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'loop',
|
||||||
|
aliases: ['lp'],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}loop',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
||||||
|
|
||||||
|
if (client.player.getQueue(message).repeatMode) {
|
||||||
|
client.player.setRepeatMode(message, false);
|
||||||
|
return message.channel.send(`${client.emotes.success} - Repeat mode **disabled** !`);
|
||||||
|
} else {
|
||||||
|
client.player.setRepeatMode(message, true);
|
||||||
|
return message.channel.send(`${client.emotes.success} - Repeat mode **enabled** !`);
|
||||||
|
};
|
||||||
|
},
|
||||||
|
};
|
||||||
44
commands/music/nowplaying.js
Normal file
44
commands/music/nowplaying.js
Normal file
@@ -0,0 +1,44 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'nowplaying',
|
||||||
|
aliases: ['np'],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}nowplaying',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
||||||
|
|
||||||
|
const track = client.player.nowPlaying(message);
|
||||||
|
const filters = [];
|
||||||
|
|
||||||
|
Object.keys(client.player.getQueue(message).filters).forEach((filterName) => {
|
||||||
|
if (client.player.getQueue(message).filters[filterName]) filters.push(filterName);
|
||||||
|
});
|
||||||
|
|
||||||
|
message.channel.send({
|
||||||
|
embed: {
|
||||||
|
color: 'RED',
|
||||||
|
author: { name: track.title },
|
||||||
|
footer: { text: 'This bot uses a Github project made by Zerio (ZerioDev/Music-bot)' },
|
||||||
|
fields: [
|
||||||
|
{ name: 'Channel', value: track.author, inline: true },
|
||||||
|
{ name: 'Requested by', value: track.requestedBy.username, inline: true },
|
||||||
|
{ name: 'From playlist', value: track.fromPlaylist ? 'Yes' : 'No', inline: true },
|
||||||
|
|
||||||
|
{ name: 'Views', value: track.views, inline: true },
|
||||||
|
{ name: 'Duration', value: track.duration, inline: true },
|
||||||
|
{ name: 'Filters activated', value: filters.length, inline: true },
|
||||||
|
|
||||||
|
{ name: 'Volume', value: client.player.getQueue(message).volume, inline: true },
|
||||||
|
{ name: 'Repeat mode', value: client.player.getQueue(message).repeatMode ? 'Yes' : 'No', inline: true },
|
||||||
|
{ name: 'Currently paused', value: client.player.getQueue(message).paused ? 'Yes' : 'No', inline: true },
|
||||||
|
|
||||||
|
{ name: 'Progress bar', value: client.player.createProgressBar(message, { timecodes: true }), inline: true }
|
||||||
|
],
|
||||||
|
thumbnail: { url: track.thumbnail },
|
||||||
|
timestamp: new Date(),
|
||||||
|
},
|
||||||
|
});
|
||||||
|
},
|
||||||
|
};
|
||||||
18
commands/music/pause.js
Normal file
18
commands/music/pause.js
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'pause',
|
||||||
|
aliases: [],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}pause',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
||||||
|
|
||||||
|
if (client.player.getQueue(message).paused) return message.channel.send(`${client.emotes.error} - The music is already paused !`);
|
||||||
|
|
||||||
|
client.player.pause(message);
|
||||||
|
|
||||||
|
message.channel.send(`${client.emotes.success} - Song ${client.player.getQueue(message).playing.title} **paused** !`);
|
||||||
|
},
|
||||||
|
};
|
||||||
14
commands/music/play.js
Normal file
14
commands/music/play.js
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'play',
|
||||||
|
aliases: ['p'],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}play [name/URL]',
|
||||||
|
|
||||||
|
execute(client, message, args) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!args[0]) return message.channel.send(`${client.emotes.error} - Please indicate the title of a song !`);
|
||||||
|
|
||||||
|
client.player.play(message, args.join(" "));
|
||||||
|
},
|
||||||
|
};
|
||||||
18
commands/music/queue.js
Normal file
18
commands/music/queue.js
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'queue',
|
||||||
|
aliases: [],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}queue',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
const queue = client.player.getQueue(message);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No songs currently playing !`);
|
||||||
|
|
||||||
|
message.channel.send(`**Server queue - ${message.guild.name} ${client.emotes.queue}**\nCurrent : ${queue.playing.title} | ${queue.playing.author}\n\n` + (queue.tracks.map((track, i) => {
|
||||||
|
return `**#${i + 1}** - ${track.title} | ${track.author} (requested by : ${track.requestedBy.username})`
|
||||||
|
}).slice(0, 5).join('\n') + `\n\n${queue.tracks.length > 5 ? `And **${queue.tracks.length - 5}** other songs...` : `In the playlist **${queue.tracks.length}** song(s)...`}`));
|
||||||
|
},
|
||||||
|
};
|
||||||
18
commands/music/resume.js
Normal file
18
commands/music/resume.js
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'resume',
|
||||||
|
aliases: [],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}resume',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message).paused) return message.channel.send(`${client.emotes.error} - The music is already playing !`);
|
||||||
|
|
||||||
|
client.player.resume(message);
|
||||||
|
|
||||||
|
message.channel.send(`${client.emotes.success} - Song ${client.player.getQueue(message).playing.title} **resumed** !`);
|
||||||
|
},
|
||||||
|
};
|
||||||
16
commands/music/shuffle.js
Normal file
16
commands/music/shuffle.js
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'shuffle',
|
||||||
|
aliases: ['sh'],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}shuffle',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
||||||
|
|
||||||
|
client.player.shuffle(message);
|
||||||
|
|
||||||
|
return message.channel.send(`${client.emotes.success} - Queue shuffled **${client.player.getQueue(message).tracks.length}** song(s) !`);
|
||||||
|
},
|
||||||
|
};
|
||||||
16
commands/music/skip.js
Normal file
16
commands/music/skip.js
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'skip',
|
||||||
|
aliases: ['sk'],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}skip',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
||||||
|
|
||||||
|
client.player.skip(message);
|
||||||
|
|
||||||
|
message.channel.send(`${client.emotes.success} - The current music has just been **skipped** !`);
|
||||||
|
},
|
||||||
|
};
|
||||||
17
commands/music/stop.js
Normal file
17
commands/music/stop.js
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'stop',
|
||||||
|
aliases: [],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}stop',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
||||||
|
|
||||||
|
client.player.setRepeatMode(message, false);
|
||||||
|
client.player.stop(message);
|
||||||
|
|
||||||
|
message.channel.send(`${client.emotes.success} - Music **stopped** into this server !`);
|
||||||
|
},
|
||||||
|
};
|
||||||
20
commands/music/volume.js
Normal file
20
commands/music/volume.js
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'volume',
|
||||||
|
aliases: [],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}volume [1-100]',
|
||||||
|
|
||||||
|
execute(client, message, args) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
||||||
|
|
||||||
|
if (!args[0] || isNaN(args[0])) return message.channel.send(`${client.emotes.error} - Please enter a valid number !`);
|
||||||
|
|
||||||
|
if (Math.round(parseInt(args[0])) < 1 || Math.round(parseInt(args[0])) > 100) return message.channel.send(`${client.emotes.error} - Please enter a valid number (between 1 and 100) !`);
|
||||||
|
|
||||||
|
client.player.setVolume(message, args[0]);
|
||||||
|
|
||||||
|
message.channel.send(`${client.emotes.success} - Volume set to **${parseInt(args[0])}%** !`);
|
||||||
|
},
|
||||||
|
};
|
||||||
35
commands/music/w-filters.js
Normal file
35
commands/music/w-filters.js
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
module.exports = {
|
||||||
|
name: 'w-filters',
|
||||||
|
aliases: ['filters'],
|
||||||
|
category: 'Music',
|
||||||
|
utilisation: '{prefix}w-filters',
|
||||||
|
|
||||||
|
execute(client, message) {
|
||||||
|
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
||||||
|
|
||||||
|
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
||||||
|
|
||||||
|
const disabledEmoji = client.emotes.error;
|
||||||
|
const enabledEmoji = client.emotes.success;
|
||||||
|
|
||||||
|
const filtersStatuses = [[], []];
|
||||||
|
|
||||||
|
Object.keys(client.filters).forEach((filterName) => {
|
||||||
|
const array = filtersStatuses[0].length > filtersStatuses[1].length ? filtersStatuses[1] : filtersStatuses[0];
|
||||||
|
array.push(client.filters[filterName] + " : " + (client.player.getQueue(message).filters[filterName] ? enabledEmoji : disabledEmoji));
|
||||||
|
});
|
||||||
|
|
||||||
|
message.channel.send({
|
||||||
|
embed: {
|
||||||
|
color: 'ORANGE',
|
||||||
|
footer: { text: 'This bot uses a Github project made by Zerio (ZerioDev/Music-bot)' },
|
||||||
|
fields: [
|
||||||
|
{ name: 'Filters', value: filtersStatuses[0].join('\n'), inline: true },
|
||||||
|
{ name: '** **', value: filtersStatuses[1].join('\n'), inline: true },
|
||||||
|
],
|
||||||
|
timestamp: new Date(),
|
||||||
|
description: `List of all filters enabled or disabled.\nUse \`${client.config.prefix}filter\` to add a filter to a song.`,
|
||||||
|
},
|
||||||
|
});
|
||||||
|
},
|
||||||
|
};
|
||||||
@@ -1,35 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
|
||||||
|
|
||||||
const track = await client.player.nowPlaying(message);
|
|
||||||
const filters = [];
|
|
||||||
|
|
||||||
Object.keys(client.player.getQueue(message).filters).forEach((filterName) => {
|
|
||||||
if (client.player.getQueue(message).filters[filterName]) filters.push(filterName);
|
|
||||||
});
|
|
||||||
|
|
||||||
message.channel.send({
|
|
||||||
embed: {
|
|
||||||
color: 'RED',
|
|
||||||
author: { name: track.title },
|
|
||||||
footer: { text: 'This bot uses a Github project made by Zerio (ZerioDev/Music-bot)' },
|
|
||||||
fields: [
|
|
||||||
{ name: 'Channel', value: track.author, inline: true },
|
|
||||||
{ name: 'Requested by', value: track.requestedBy.username, inline: true },
|
|
||||||
{ name: 'From playlist', value: track.fromPlaylist ? 'Yes' : 'No', inline: true },
|
|
||||||
|
|
||||||
{ name: 'Views', value: track.views, inline: true },
|
|
||||||
{ name: 'Duration', value: track.duration, inline: true },
|
|
||||||
{ name: 'Filters activated', value: filters.length, inline: true },
|
|
||||||
|
|
||||||
{ name: 'Progress bar', value: client.player.createProgressBar(message, { timecodes: true }), inline: true }
|
|
||||||
],
|
|
||||||
thumbnail: { url: track.thumbnail },
|
|
||||||
timestamp: new Date(),
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
|
||||||
|
|
||||||
client.player.pause(message);
|
|
||||||
|
|
||||||
message.channel.send(`${client.emotes.success} - Song ${client.player.getQueue(message).playing.title} **paused** !`);
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
message.channel.send(`${client.emotes.success} - Ping : **${client.ws.ping}ms** !`);
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
exports.run = async (client, message, args) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!args[0]) return message.channel.send(`${client.emotes.error} - Please indicate the title of a song !`);
|
|
||||||
|
|
||||||
client.player.play(message, args.join(" "));
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
const queue = client.player.getQueue(message);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No songs currently playing !`);
|
|
||||||
|
|
||||||
message.channel.send(`**Server queue - ${message.guild.name} ${client.emotes.queue}**\nCurrent : ${queue.playing.title} | ${queue.playing.author}\n\n` + (queue.tracks.map((track, i) => {
|
|
||||||
return `**#${i + 1}** - ${track.title} | ${track.author} (requested by : ${track.requestedBy.username})`
|
|
||||||
}).slice(0, 5).join('\n') + `\n\n${queue.tracks.length > 5 ? `And **${queue.tracks.length - 5}** other songs...` : `In the playlist **${queue.tracks.length}** song(s)...`}`));
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
|
||||||
|
|
||||||
client.player.resume(message);
|
|
||||||
|
|
||||||
message.channel.send(`${client.emotes.success} - Song ${client.player.getQueue(message).playing.title} **resumed** !`);
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
|
||||||
|
|
||||||
client.player.shuffle(message);
|
|
||||||
|
|
||||||
return message.channel.send(`${client.emotes.success} - Queue shuffled **${client.player.getQueue(message).tracks.length}** song(s) !`);
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
|
||||||
|
|
||||||
client.player.skip(message);
|
|
||||||
|
|
||||||
message.channel.send(`${client.emotes.success} - The current music has just been **skipped** !`);
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,12 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
|
||||||
|
|
||||||
client.player.setRepeatMode(message, false);
|
|
||||||
client.player.stop(message);
|
|
||||||
|
|
||||||
message.channel.send(`${client.emotes.success} - Music **stopped** into this server !`);
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,17 +0,0 @@
|
|||||||
exports.run = async (client, message, args) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
|
||||||
|
|
||||||
if (!args[0]) return message.channel.send(`${client.emotes.error} - Please enter a number !`);
|
|
||||||
|
|
||||||
if (isNaN(args[0]) || 100 < args[0] || args[0] <= 0) return message.channel.send(`${client.emotes.error} - Please enter a valid number (between 1 and 100) !`);
|
|
||||||
|
|
||||||
if (message.content.includes('-') || message.content.includes('+') || message.content.includes(',') || message.content.includes('.')) return message.channel.send(`${client.emotes.error} - Please enter a valid number !`);
|
|
||||||
|
|
||||||
client.player.setVolume(message, parseInt(args[0]));
|
|
||||||
|
|
||||||
message.channel.send(`${client.emotes.success} - Volume set to **${args.join(" ")}%** !`);
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
exports.run = async (client, message) => {
|
|
||||||
|
|
||||||
if (!message.member.voice.channel) return message.channel.send(`${client.emotes.error} - You're not in a voice channel !`);
|
|
||||||
|
|
||||||
if (!client.player.getQueue(message)) return message.channel.send(`${client.emotes.error} - No music currently playing !`);
|
|
||||||
|
|
||||||
const disabledEmoji = client.emotes.error;
|
|
||||||
const enabledEmoji = client.emotes.success;
|
|
||||||
|
|
||||||
const filtersStatuses = [[], []];
|
|
||||||
|
|
||||||
Object.keys(client.filters).forEach((filterName) => {
|
|
||||||
const array = filtersStatuses[0].length > filtersStatuses[1].length ? filtersStatuses[1] : filtersStatuses[0];
|
|
||||||
array.push(client.filters[filterName] + " : " + (client.player.getQueue(message).filters[filterName] ? enabledEmoji : disabledEmoji));
|
|
||||||
});
|
|
||||||
|
|
||||||
message.channel.send({
|
|
||||||
embed: {
|
|
||||||
color: 'ORANGE',
|
|
||||||
footer: { text: 'This bot uses a Github project made by Zerio (ZerioDev/Music-bot)' },
|
|
||||||
fields: [
|
|
||||||
{ name: 'Filters', value: filtersStatuses[0].join('\n'), inline: true },
|
|
||||||
{ name: '** **', value: filtersStatuses[1].join('\n'), inline: true },
|
|
||||||
],
|
|
||||||
timestamp: new Date(),
|
|
||||||
description: `List of all filters enabled or disabled.\nUse \`${client.config.prefix}filter\` to add a filter to a song.`,
|
|
||||||
},
|
|
||||||
});
|
|
||||||
|
|
||||||
};
|
|
||||||
@@ -2,4 +2,4 @@
|
|||||||
"game": "GAME",
|
"game": "GAME",
|
||||||
"prefix": "PREFIX",
|
"prefix": "PREFIX",
|
||||||
"token_bot": "TOKEN"
|
"token_bot": "TOKEN"
|
||||||
}
|
}
|
||||||
@@ -9,10 +9,8 @@ module.exports = (client, message) => {
|
|||||||
const args = message.content.slice(prefix.length).trim().split(/ +/g);
|
const args = message.content.slice(prefix.length).trim().split(/ +/g);
|
||||||
const command = args.shift().toLowerCase();
|
const command = args.shift().toLowerCase();
|
||||||
|
|
||||||
const cmd = client.commands.get(command);
|
const cmd = client.commands.get(command) || client.commands.find(cmd => cmd.aliases && cmd.aliases.includes(command));
|
||||||
|
|
||||||
if (!cmd) return;
|
if (cmd) cmd.execute(client, message, args);
|
||||||
|
|
||||||
cmd.run(client, message, args);
|
};
|
||||||
|
|
||||||
};
|
|
||||||
@@ -4,4 +4,4 @@ module.exports = async (client) => {
|
|||||||
|
|
||||||
client.user.setActivity(client.config.game);
|
client.user.setActivity(client.config.game);
|
||||||
|
|
||||||
};
|
};
|
||||||
67
index.js
67
index.js
@@ -5,42 +5,47 @@ const client = new discord.Client({ disableMentions: 'everyone' });
|
|||||||
|
|
||||||
const { Player } = require('discord-player');
|
const { Player } = require('discord-player');
|
||||||
|
|
||||||
const player = new Player(client);
|
client.player = new Player(client);
|
||||||
client.player = player;
|
|
||||||
client.config = require('./config/bot.json');
|
client.config = require('./config/bot.json');
|
||||||
client.emotes = require('./config/emojis.json');
|
client.emotes = require('./config/emojis.json');
|
||||||
client.filters = require('./config/filters.json');
|
client.filters = require('./config/filters.json');
|
||||||
client.commands = new discord.Collection();
|
client.commands = new discord.Collection();
|
||||||
|
|
||||||
fs.readdir('./events/', (err, files) => {
|
const core = fs.readdirSync('./commands/core').filter(file => file.endsWith('.js'));
|
||||||
if (err) return console.error(err);
|
const infos = fs.readdirSync('./commands/infos').filter(file => file.endsWith('.js'));
|
||||||
files.forEach(file => {
|
const music = fs.readdirSync('./commands/music').filter(file => file.endsWith('.js'));
|
||||||
const event = require(`./events/${file}`);
|
|
||||||
let eventName = file.split(".")[0];
|
|
||||||
console.log(`Loading event ${eventName}`);
|
|
||||||
client.on(eventName, event.bind(null, client));
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
fs.readdir('./player-events/', (err, files) => {
|
for (const file of core) {
|
||||||
if (err) return console.error(err);
|
console.log(`Loading command ${file}`);
|
||||||
files.forEach(file => {
|
const command = require(`./commands/core/${file}`);
|
||||||
const event = require(`./player-events/${file}`);
|
client.commands.set(command.name.toLowerCase(), command);
|
||||||
let eventName = file.split(".")[0];
|
};
|
||||||
console.log(`Loading player event ${eventName}`);
|
|
||||||
client.player.on(eventName, event.bind(null, client));
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
fs.readdir('./commands/', (err, files) => {
|
for (const file of infos) {
|
||||||
if (err) return console.error(err);
|
console.log(`Loading command ${file}`);
|
||||||
files.forEach(file => {
|
const command = require(`./commands/infos/${file}`);
|
||||||
if (!file.endsWith(".js")) return;
|
client.commands.set(command.name.toLowerCase(), command);
|
||||||
let props = require(`./commands/${file}`);
|
};
|
||||||
let commandName = file.split(".")[0];
|
|
||||||
console.log(`Loading command ${commandName}`);
|
|
||||||
client.commands.set(commandName, props);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
|
|
||||||
client.login(client.config.token_bot);
|
for (const file of music) {
|
||||||
|
console.log(`Loading command ${file}`);
|
||||||
|
const command = require(`./commands/music/${file}`);
|
||||||
|
client.commands.set(command.name.toLowerCase(), command);
|
||||||
|
};
|
||||||
|
|
||||||
|
const events = fs.readdirSync('./events').filter(file => file.endsWith('.js'));
|
||||||
|
const player = fs.readdirSync('./player').filter(file => file.endsWith('.js'));
|
||||||
|
|
||||||
|
for (const file of events) {
|
||||||
|
console.log(`Loading discord.js event ${file}`);
|
||||||
|
const event = require(`./events/${file}`);
|
||||||
|
client.on(file.split(".")[0], event.bind(null, client));
|
||||||
|
};
|
||||||
|
|
||||||
|
for (const file of player) {
|
||||||
|
console.log(`Loading discord-player event ${file}`);
|
||||||
|
const event = require(`./player/${file}`);
|
||||||
|
client.player.on(file.split(".")[0], event.bind(null, client));
|
||||||
|
};
|
||||||
|
|
||||||
|
client.login(client.config.token_bot);
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "music-bot",
|
"name": "music-bot",
|
||||||
"version": "2.0.1",
|
"version": "3.0.0",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"repository": "https://github.com/ZerioDev/Music-bot.git",
|
"repository": "https://github.com/ZerioDev/Music-bot.git",
|
||||||
"author": "ZerioDev",
|
"author": "ZerioDev",
|
||||||
@@ -11,4 +11,4 @@
|
|||||||
"discord.js": "^12.2.0",
|
"discord.js": "^12.2.0",
|
||||||
"ffmpeg-static": "^4.2.7"
|
"ffmpeg-static": "^4.2.7"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1,5 +1,3 @@
|
|||||||
module.exports = (client, message, queue) => {
|
module.exports = (client, message, queue) => {
|
||||||
|
|
||||||
message.channel.send(`${client.emotes.error} - Music stopped as i have been disconnected from the channel !`);
|
message.channel.send(`${client.emotes.error} - Music stopped as i have been disconnected from the channel !`);
|
||||||
|
};
|
||||||
};
|
|
||||||
@@ -1,5 +1,3 @@
|
|||||||
module.exports = (client, message, queue) => {
|
module.exports = (client, message, queue) => {
|
||||||
|
message.channel.send(`${client.emotes.error} - Music stopped as there is no more member in the voice channel !`);
|
||||||
message.channel.send(`${client.emotes.error} - Music stopped as there is no more member in the voice channel !`);
|
|
||||||
|
|
||||||
};
|
};
|
||||||
@@ -1,17 +1,15 @@
|
|||||||
module.exports = (client, error, message) => {
|
module.exports = (client, error, message) => {
|
||||||
|
switch (error) {
|
||||||
switch (error) {
|
case 'NotPlaying':
|
||||||
case 'NotPlaying':
|
message.channel.send(`${client.emotes.error} - There is no music being played on this server !`);
|
||||||
message.channel.send(`${client.emotes.error} - There is no music being played on this server !`);
|
break;
|
||||||
break;
|
case 'NotConnected':
|
||||||
case 'NotConnected':
|
message.channel.send(`${client.emotes.error} - You are not connected in any voice channel !`);
|
||||||
message.channel.send(`${client.emotes.error} - You are not connected in any voice channel !`);
|
break;
|
||||||
break;
|
case 'UnableToJoin':
|
||||||
case 'UnableToJoin':
|
message.channel.send(`${client.emotes.error} - I am not able to join your voice channel, please check my permissions !`);
|
||||||
message.channel.send(`${client.emotes.error} - I am not able to join your voice channel, please check my permissions !`);
|
break;
|
||||||
break;
|
default:
|
||||||
default:
|
message.channel.send(`${client.emotes.error} - Something went wrong ... Error : ${error}`);
|
||||||
message.channel.send(`${client.emotes.error} - Something went wrong ... Error : ${error}`);
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
};
|
|
||||||
@@ -1,5 +1,3 @@
|
|||||||
module.exports = (client, message, query) => {
|
module.exports = (client, message, query) => {
|
||||||
|
message.channel.send(`${client.emotes.error} - No results found on YouTube for ${query} !`);
|
||||||
message.channel.send(`${client.emotes.error} - No results found on YouTube for ${query} !`);
|
|
||||||
|
|
||||||
};
|
};
|
||||||
@@ -1,5 +1,3 @@
|
|||||||
module.exports = (client, message, playlist) => {
|
module.exports = (client, message, playlist) => {
|
||||||
|
message.channel.send(`${client.emotes.music} - ${playlist.title} has been added to the queue (**${playlist.items.length}** songs) !`);
|
||||||
message.channel.send(`${client.emotes.music} - ${playlist.title} has been added to the queue (**${playlist.items.length}** songs) !`);
|
|
||||||
|
|
||||||
};
|
};
|
||||||
@@ -1,5 +1,3 @@
|
|||||||
module.exports = (client, message, queue) => {
|
module.exports = (client, message, queue) => {
|
||||||
|
message.channel.send(`${client.emotes.error} - Music stopped as there is no more music in the queue !`);
|
||||||
message.channel.send(`${client.emotes.error} - Music stopped as there is no more music in the queue !`);
|
|
||||||
|
|
||||||
};
|
};
|
||||||
@@ -1,5 +1,3 @@
|
|||||||
module.exports = (client, message, query, tracks) => {
|
module.exports = (client, message, query, tracks) => {
|
||||||
|
message.channel.send(`${client.emotes.error} - You did not provide a valid response ... Please send the command again !`);
|
||||||
message.channel.send(`${client.emotes.error} - You did not provide a valid response ... Please send the command again !`);
|
|
||||||
|
|
||||||
};
|
};
|
||||||
@@ -1,5 +1,3 @@
|
|||||||
module.exports = (client, message, query, tracks, content, collector) => {
|
module.exports = (client, message, query, tracks, content, collector) => {
|
||||||
|
message.channel.send(`${client.emotes.error} - You must send a valid number between **1** and **${tracks.length}** !`);
|
||||||
message.channel.send(`${client.emotes.error} - You must send a valid number between **1** and **${tracks.length}** !`);
|
|
||||||
|
|
||||||
};
|
};
|
||||||
@@ -1,13 +1,11 @@
|
|||||||
module.exports = (client, message, query, tracks) => {
|
module.exports = (client, message, query, tracks) => {
|
||||||
|
message.channel.send({
|
||||||
message.channel.send({
|
embed: {
|
||||||
embed: {
|
color: 'BLUE',
|
||||||
color: 'BLUE',
|
author: { name: `Here are your search results for ${query}` },
|
||||||
author: { name: `Here are your search results for ${query}` },
|
footer: { text: 'This bot uses a Github project made by Zerio (ZerioDev/Music-bot)' },
|
||||||
footer: { text: 'This bot uses a Github project made by Zerio (ZerioDev/Music-bot)' },
|
timestamp: new Date(),
|
||||||
timestamp: new Date(),
|
description: `${tracks.map((t, i) => `**${i + 1}** - ${t.title}`).join('\n')}`,
|
||||||
description: `${tracks.map((t, i) => `**${i + 1}** - ${t.title}`).join('\n')}`,
|
},
|
||||||
},
|
});
|
||||||
});
|
|
||||||
|
|
||||||
};
|
};
|
||||||
@@ -1,5 +1,3 @@
|
|||||||
module.exports = (client, message, queue, track) => {
|
module.exports = (client, message, queue, track) => {
|
||||||
|
message.channel.send(`${client.emotes.music} - ${track.title} has been added to the queue !`);
|
||||||
message.channel.send(`${client.emotes.music} - ${track.title} has been added to the queue !`);
|
|
||||||
|
|
||||||
};
|
};
|
||||||
@@ -1,5 +1,3 @@
|
|||||||
module.exports = (client, message, track) => {
|
module.exports = (client, message, track) => {
|
||||||
|
message.channel.send(`${client.emotes.music} - Now playing ${track.title} into ${message.member.voice.channel.name} ...`);
|
||||||
message.channel.send(`${client.emotes.music} - Now playing ${track.title} into ${message.member.voice.channel.name} ...`);
|
|
||||||
|
|
||||||
};
|
};
|
||||||
Reference in New Issue
Block a user