From 00de13acd2051ebb0d97a555f1df43d6918bd428 Mon Sep 17 00:00:00 2001 From: Bradley Bickford Date: Wed, 22 Nov 2023 21:57:26 -0500 Subject: [PATCH] Switched back to the old version and turning CRC back on --- breadbot.js | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/breadbot.js b/breadbot.js index add8fa0..2565d2a 100644 --- a/breadbot.js +++ b/breadbot.js @@ -134,16 +134,10 @@ client.on(Events.VoiceStateUpdate, async (oldState, newState) => { }), pageSizeControl: { maxPackets: 10 - }, - crc: false + }/*, + crc: false*/ })) - .pipe(new prism.opus.OggDemuxer()) - .pipe(new prism.opus.Decoder({ - channels: 2, - rate: 4800, - frameSize: 960 - })) - .pipe(fs.createWriteStream("." + path.sep + "media" + path.sep + "voice_audio" + path.sep + newCallID + path.sep + `${Date.now()}-${user_id}.pcm`)) + .pipe(fs.createWriteStream("." + path.sep + "media" + path.sep + "voice_audio" + path.sep + newCallID + path.sep + `${Date.now()}-${user_id}.ogg`)) }) } catch (error) {