mirror of
https://github.com/danbulant/discord.js
synced 2026-06-08 17:21:31 +00:00
Fix Opus voice streams (#3555)
This fixes a wrong assumption about incoming discord voice packets revealed during a recent discord change that broke incoming opus voice streams
This commit is contained in:
parent
9bcb6a04ba
commit
3a9eb5b929
1 changed files with 3 additions and 1 deletions
|
|
@ -63,7 +63,9 @@ class PacketHandler extends EventEmitter {
|
||||||
if (byte === 0) continue;
|
if (byte === 0) continue;
|
||||||
offset += 1 + (0b1111 & (byte >> 4));
|
offset += 1 + (0b1111 & (byte >> 4));
|
||||||
}
|
}
|
||||||
while (packet[offset] === 0) offset++;
|
// Skip over undocumented Discord byte
|
||||||
|
offset++;
|
||||||
|
|
||||||
packet = packet.slice(offset);
|
packet = packet.slice(offset);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue