mirror of
https://github.com/danbulant/discord.js
synced 2026-05-25 13:02:38 +00:00
Add playFile back to voice connection
This commit is contained in:
parent
0a47d0e1d6
commit
4294d267e7
1 changed files with 3 additions and 2 deletions
|
|
@ -231,8 +231,9 @@ class VoiceConnection extends EventEmitter {
|
|||
* })
|
||||
* .catch(console.error);
|
||||
*/
|
||||
playFile(file, options) {
|
||||
return this.playStream(fs.createReadStream(file), options);
|
||||
playFile(file, { seek = 0, volume = 1, passes = 1 } = {}) {
|
||||
const options = { seek, volume, passes };
|
||||
return this.player.playUnknownStream(file, options);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue