1
0
mirror of https://github.com/musix-org/musix-oss synced 2024-12-23 03:33:17 +00:00

Update play.js

This commit is contained in:
Matte 2019-10-20 21:21:51 +03:00 committed by GitHub
parent 1d0fcb6fae
commit 9f571c10d7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -7,7 +7,7 @@ module.exports = async function (guild, song, client, message, seek) {
client.queue.delete(guild.id); client.queue.delete(guild.id);
return; return;
} }
const dispatcher = serverQueue.connection const dispatcher = message.guild.voiceConnection.playStream
.playStream(ytdl(song.url, { filter: "audio", highWaterMark: 1 << 25 }), { seek: seek, bitrate: 1024, passes: 10, volume: 1 }) .playStream(ytdl(song.url, { filter: "audio", highWaterMark: 1 << 25 }), { seek: seek, bitrate: 1024, passes: 10, volume: 1 })
.on("end", reason => { .on("end", reason => {
if (reason === "Stream is not generating quickly enough.") { if (reason === "Stream is not generating quickly enough.") {