Fix timestamp 3rd edition
helps to supply ytdl arguments to, you know, ytdl
This commit is contained in:
parent
ed28d27738
commit
4b71fe1b02
2
bot.js
2
bot.js
@ -165,7 +165,7 @@ client.on('message', async message => {
|
||||
// Play the video as requested
|
||||
try {
|
||||
//TODO: process the timestamp with ffmpeg or whatever
|
||||
const dispatcher = connection.play(await ytdl(yturl), { type: 'opus', volume: volume, begin: timestamp});
|
||||
const dispatcher = connection.play(await ytdl(yturl, { begin: timestamp }), { type: 'opus', volume: volume});
|
||||
dispatcher.on('start', () => { console.log(`Playing ${yturl}`); });
|
||||
dispatcher.on('finish', () => { console.log(`Finished ${yturl}`); });
|
||||
dispatcher.on('error', console.error);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user