mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-09 16:13:31 +01:00
Update channel improvements
Also documented two methods for voice connections. (pause and resume)
This commit is contained in:
@@ -534,7 +534,7 @@ Sets the name and topic of a channel
|
||||
- **error** - error if any occurred
|
||||
|
||||
setChannelUserLimit(channel, limit, `callback`)
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Sets the user limit of a voice channel
|
||||
|
||||
@@ -544,7 +544,7 @@ Sets the user limit of a voice channel
|
||||
- **error** - error if any occurred
|
||||
|
||||
setChannelBitrate(channel, bitrate, `callback`)
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Sets the bitrate of a voice channel
|
||||
|
||||
@@ -553,6 +553,21 @@ Sets the bitrate of a voice channel
|
||||
- **callback** - `function` taking the following:
|
||||
- **error** - error if any occurred
|
||||
|
||||
updateChannel(channel, data, `callback`)
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Updates the settings of a channel
|
||||
|
||||
- **channel** - A `Channel Resolvable`_
|
||||
- **details** - `object` containing any of the following:
|
||||
- **name** - `String`, the new name of channel
|
||||
- **topic** - `String`, the new topic of the channel (`TextChannel`_ only)
|
||||
- **position** - `Number`, the new position of the channel
|
||||
- **userLimit** - `Number`, the new user limit of the channel (`VoiceChannel`_ only)
|
||||
- **bitrate** - `Number`, the new bitrate (in kb/s) of the channel (`VoiceChannel`_ only)
|
||||
- **callback** - `function` taking the following:
|
||||
- **error** - error if any occurred
|
||||
|
||||
startTyping(channel, `callback`)
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
|
||||
@@ -51,3 +51,9 @@ mention()
|
||||
~~~~~~~~~
|
||||
|
||||
Returns a `string` that can be used in discord messages to mention a channel. `serverChannel.toString()` defaults to this.
|
||||
|
||||
update(data, `callback`)
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
| **Shortcut of** ``client.updateChannel(channel, data, callback)``
|
||||
| **See** client.updateChannel_
|
||||
|
||||
@@ -120,6 +120,16 @@ getVolume()
|
||||
|
||||
Returns the current volume. 1.0 is normal, 0.5 is half as loud, 2.0 is twice as loud.
|
||||
|
||||
pause()
|
||||
~~~~~~~
|
||||
|
||||
Pauses the current connection's audio.
|
||||
|
||||
resume()
|
||||
~~~~~~~~
|
||||
|
||||
Resumes the current connection's audio.
|
||||
|
||||
stopPlaying()
|
||||
~~~~~~~~~~~~~
|
||||
|
||||
|
||||
Reference in New Issue
Block a user