-
Notifications
You must be signed in to change notification settings - Fork 149
VoiceConnection
SinisterRectus edited this page Jan 14, 2017
·
13 revisions
| Name | Type | Mutable | Description |
|---|---|---|---|
| channel | GuildVoiceChannel | The channel for which the connection exists. | |
| isPlaying | boolean | Whether audio is currently playing on the connection. |
| Prototype | Description |
|---|---|
| getBitrate() | Returns the current bitrate for the connection in bits per second. |
| pauseStream() | Pauses the current audio stream, if one exists and is playing. |
| playBytes(string[, duration]) | Interprets a Lua string as a byte array and streams it. |
| playFile(filename[, duration]) | Streams an audio file via FFmpeg. |
| playPCM(table[, duration]) | Interprets a Lua table as a PCM array and streams it. |
| playWaveform(generator[, duration]) | Streams PCM data returned from a generator function. |
| resumeStream() | Resumes the current audio stream, if one exists and is paused. |
| setBitrate() | Sets the current bitrate for the connection (8000 to 128000 bps range). |
| stopStream() | Stops the current audio stream, if one exists. |