Nostrum.Voice.pause
You're seeing just the function
pause
, go back to Nostrum.Voice module for more information.
Specs
pause(Nostrum.Struct.Guild.id()) :: :ok | {:error, String.t()}
Pauses the current sound being played in a voice channel.
The bot must be connected to a voice channel in the guild specified.
Parameters
guild_id
- ID of guild whose voice channel the sound will be paused in.
Returns {:error, reason}
if unable to pause or no sound is playing, else :ok
.
This function is similar to stop/1
, except that the sound may be
resumed after being paused.
Examples
iex> Nostrum.Voice.join_channel(123456789, 420691337)
iex> Nostrum.Voice.play(123456789, "~/files/twelve_hour_loop_of_waterfall_sounds.mp3")
iex> Nostrum.Voice.pause(123456789)