diff --git a/commands/bug.js b/commands/bug.js index 88bdd70d..c6855486 100644 --- a/commands/bug.js +++ b/commands/bug.js @@ -1,6 +1,7 @@ module.exports = { name: 'bug', description: 'Report a bug', + alias: 'bug', cooldown: 5, async execute(message, args, client, Discord, prefix) { const embed = new Discord.RichEmbed() diff --git a/commands/eval.js b/commands/eval.js index 88e2630f..8065592c 100644 --- a/commands/eval.js +++ b/commands/eval.js @@ -1,6 +1,7 @@ module.exports = { name: 'eval', description: 'Evaluation command', + alias: 'eval', cooldown: 5, async execute(message, args, client, Discord, prefix) { const ytdl = require('ytdl-core'); @@ -8,7 +9,7 @@ module.exports = { if (serverQueue) { let data = await Promise.resolve(ytdl.getInfo(serverQueue.songs[0].url)); } - if (message.author.id !== '360363051792203779') return message.channel.send(':x: You are not allowed to do that!'); + if (message.author.id !== client.global.devId) return message.channel.send(':x: You are not allowed to do that!'); const input = message.content.slice(prefix.length + 4); let output; try { diff --git a/commands/forcestop.js b/commands/forcestop.js index 415e4a23..4548ea13 100644 --- a/commands/forcestop.js +++ b/commands/forcestop.js @@ -1,9 +1,10 @@ module.exports = { name: 'forcestop', description: 'force stop command.', + alias: 'fs', cooldown: 5, execute(message, args, client, Discord, prefix) { - if (message.author.id !== '360363051792203779') return message.channel.send(':x: You are not allowed to do that!') + if (message.author.id !== client.global.devId) return message.channel.send(':x: You are not allowed to do that!') client.queue.delete(message.guild.id); message.channel.send('queue deleted') } diff --git a/commands/help.js b/commands/help.js index 0c75e2dc..7c4c68fe 100644 --- a/commands/help.js +++ b/commands/help.js @@ -1,6 +1,7 @@ module.exports = { name: 'help', description: 'Help command.', + alias: 'help', cooldown: 5, execute(message, args, client, Discord, prefix) { const embed = new Discord.RichEmbed() diff --git a/commands/invite.js b/commands/invite.js index b4fbbf58..1f464a25 100644 --- a/commands/invite.js +++ b/commands/invite.js @@ -1,6 +1,7 @@ module.exports = { name: 'invite', description: 'Invite command.', + alias: 'invite', cooldown: 5, execute(message, args, client, Discord, prefix) { const embed = new Discord.RichEmbed() diff --git a/commands/loop.js b/commands/loop.js index 9ef44885..9655089c 100644 --- a/commands/loop.js +++ b/commands/loop.js @@ -1,13 +1,14 @@ module.exports = { name: 'loop', description: 'loop command.', + alias: 'loop', cooldown: 10, async execute(message, args, client, Discord, prefix) { const serverQueue = client.queue.get(message.guild.id); const permissions = message.channel.permissionsFor(message.author); const { voiceChannel } = message.member; if (serverQueue) { - if (message.author.id !== '360363051792203779') { + if (message.author.id !== client.global.devId) { if (voiceChannel !== serverQueue.voiceChannel) return message.channel.send(':x: I\'m sorry but you need to be in the same voice channel as Musix to loop the queue!'); if (client.global.db.guilds[message.guild.id].permissions === true) { if (client.global.db.guilds[message.guild.id].dj) { diff --git a/commands/nowplaying.js b/commands/nowplaying.js index b33528dd..7002ba00 100644 --- a/commands/nowplaying.js +++ b/commands/nowplaying.js @@ -1,6 +1,7 @@ module.exports = { name: 'nowplaying', description: 'Now playing command.', + alias: 'np', cooldown: 5, async execute(message, args, client, Discord, prefix) { const ytdl = require('ytdl-core'); diff --git a/commands/pause.js b/commands/pause.js index 31a9bfd6..955d7cf6 100644 --- a/commands/pause.js +++ b/commands/pause.js @@ -1,6 +1,7 @@ module.exports = { name: 'pause', description: 'Pause command.', + alias: 'pause', cooldown: 5, execute(message, args, client, Discord, prefix) { const serverQueue = client.queue.get(message.guild.id); @@ -8,7 +9,7 @@ module.exports = { const { voiceChannel } = message.member; if (serverQueue && serverQueue.playing === true) { if (voiceChannel !== serverQueue.voiceChannel) return message.channel.send(':x: I\'m sorry but you need to be in the same voice channel as Musix to pause the music!'); - if (message.author.id !== '360363051792203779') { + if (message.author.id !== client.global.devId) { if (client.global.db.guilds[message.guild.id].permissions === true) { if (client.global.db.guilds[message.guild.id].dj) { if (!message.member.roles.has(client.global.db.guilds[message.guild.id].djrole)) return message.channel.send(':x: You need the `DJ` role to pause the music!'); diff --git a/commands/play.js b/commands/play.js index 37f416ac..b1836cd4 100644 --- a/commands/play.js +++ b/commands/play.js @@ -5,6 +5,7 @@ module.exports = { name: 'play', description: 'Play command.', usage: '[song name]', + alias: 'p', args: true, cooldown: 3, async execute(message, args, client, Discord, prefix) { diff --git a/commands/playlist.js b/commands/playlist.js index ef889596..33f259ac 100644 --- a/commands/playlist.js +++ b/commands/playlist.js @@ -5,152 +5,43 @@ module.exports = { name: 'playlist', usage: '[option]', description: 'Save and load queues', + alias: 'pl', cooldown: 10, async execute(message, args, client, Discord, prefix) { + const embed = new Discord.RichEmbed() + .setTitle('Options for playlist!') + .addField('play', 'Play the guild specific queue.', true) + .addField('save', 'Save the currently playing queue. Note that this will overwrite the currently saved queue!', true) + .addField('add', 'Add songs to the playlist. Like song selection', true) + .addField('remove', 'Remove songs from the playlist.', true) + .addField('list', 'Display the playlist.', true) + .setFooter(`how to use: ${prefix}playlist