discord_bot/commands/music/np.js

37 lines
1.2 KiB
JavaScript
Raw Normal View History

const { MessageEmbed } = require('discord.js')
module.exports = {
name: 'nowplaying', // Optional
aliases: ['np'], // Optional
category: 'Music',
description: 'Gibt Informationen über das Lied, das es spielt, und den Fortschritt davon',
run: async (client, message, args) => {
const voice_channel = message.member.voice.channel;
const embed = new MessageEmbed()
.setColor('#FF5757')
.setDescription(`Sie müssen sich in einem vc befinden, um diesen Befehl auszuführen!`)
if (!voice_channel) return message.channel.send(embed);
let progressBar = client.player.createProgressBar(message, {
size: 20,
block: '▬',
arrow: '🔘'
});
let song = await client.player.nowPlaying(message)
const bar = new MessageEmbed()
.setColor('#85b0d2')
.setTitle(`${song.name}`)
.setURL('https://www.youtube.com/watch?v=AFfuDgGama0')
.setDescription(`⋆ Angefordert von ${message.author}
\`${progressBar}\``)
if(progressBar)
message.channel.send(bar);
}
}