API reference
Method ConnectAsync
- Namespace
- DisCatSharp.Lavalink
- Assembly
- DisCatSharp.Lavalink.dll
ConnectAsync(DiscordChannel, bool, bool, CancellationToken)
Connects to a DiscordChannel.
public Task<LavalinkGuildPlayer> ConnectAsync(DiscordChannel channel, bool deafened = true, bool muted = false, CancellationToken cancellationToken = default)
Parameters
channelDiscordChannelThe channel to join.
deafenedboolWhether to join the channel deafened.
mutedboolWhether to join the channel muted.
cancellationTokenCancellationTokenThe cancellation token.
Returns
- Task<LavalinkGuildPlayer>
The created LavalinkGuildPlayer.