From 502fe11392decce618acf2ab680e712b79d97fd7 Mon Sep 17 00:00:00 2001 From: Snowflake107 Date: Sat, 12 Jun 2021 01:04:48 +0545 Subject: [PATCH] get the basic bot working --- src/VoiceInterface/BasicStreamDispatcher.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/VoiceInterface/BasicStreamDispatcher.ts b/src/VoiceInterface/BasicStreamDispatcher.ts index c506bd8..c163539 100644 --- a/src/VoiceInterface/BasicStreamDispatcher.ts +++ b/src/VoiceInterface/BasicStreamDispatcher.ts @@ -130,7 +130,8 @@ class BasicStreamDispatcher extends EventEmitter { async playStream(resource: AudioResource = this.audioResource) { if (!resource) throw new PlayerError("Audio resource is not available!"); if (!this.audioResource) this.audioResource = resource; - if (this.voiceConnection.state.status !== VoiceConnectionStatus.Ready) await entersState(this.voiceConnection, VoiceConnectionStatus.Ready, 20000); + if (this.voiceConnection.state.status !== VoiceConnectionStatus.Ready) + await entersState(this.voiceConnection, VoiceConnectionStatus.Ready, 20000); this.audioPlayer.play(resource); return this;