class

Discord::VoiceUDP

Inherits Reference / Object

Client for Discord's voice UDP protocol, on which the actual audio data is sent. There should be no reason to manually use this class: use VoiceClient instead which uses this class internally.

Constructors

Instance methods

connect(endpoint : String, port : UInt32, ssrc : UInt32)
Source
mode
Source
mode=(mode : Nil | String)
Source
receive_discovery_reply

Awaits a response to the discovery request and returns our local IP and port once the response is received

Source
secret_key
Source
secret_key=(secret_key : Slice(UInt8) | Nil)
Source
send_audio(buf, sequence, time)

Sends 20 ms of opus audio data to Discord, with the specified sequence and time (used on the receiving client to synchronise packets)

Source
send_discovery

Sends a discovery packet to Discord, telling them that we want to know our IP so we can select the protocol on the VWS

Source
socket
Source