Added a bit more messages on process of downloading music
This commit is contained in:
parent
2dcfa1cfac
commit
5f27195b6b
@ -47,10 +47,12 @@ module.exports = [
|
|||||||
connection = getVoiceConnection(ctx.guild.id)
|
connection = getVoiceConnection(ctx.guild.id)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const reply = await ctx.reply("Loading music data.")
|
||||||
|
|
||||||
// Running yt-dlp (getting music title)
|
// Running yt-dlp (getting music title)
|
||||||
const metadata = await ytDlp.getVideoInfo(link);
|
const metadata = await ytDlp.getVideoInfo(link);
|
||||||
|
|
||||||
ctx.reply(`Playing ${metadata.title}`)
|
await reply.edit(`Downloading ${metadata.title}`)
|
||||||
|
|
||||||
// Running yt-dlp (downloading music)
|
// Running yt-dlp (downloading music)
|
||||||
const music = ytDlp.exec([
|
const music = ytDlp.exec([
|
||||||
@ -64,6 +66,8 @@ module.exports = [
|
|||||||
'--audio-format',
|
'--audio-format',
|
||||||
'mp3'
|
'mp3'
|
||||||
]).on('close', () => {
|
]).on('close', () => {
|
||||||
|
reply.edit(`Playing ${metadata.title}`)
|
||||||
|
|
||||||
// Stopping old audioplayer
|
// Stopping old audioplayer
|
||||||
if (players[ctx.guild.id]) {
|
if (players[ctx.guild.id]) {
|
||||||
players[ctx.guild.id].stop()
|
players[ctx.guild.id].stop()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user