Table of Contents

Struct SocketVoiceState

Namespace
Kook.WebSocket
Assembly
Kook.Net.WebSocket.dll

Represents a WebSocket user's voice connection status.

public struct SocketVoiceState : IVoiceState
Implements
Inherited Members

Constructors

SocketVoiceState(SocketVoiceChannel?, bool?, bool?)

Initializes a new SocketVoiceState with the specified voice channel.

public SocketVoiceState(SocketVoiceChannel? voiceChannel, bool? isMuted, bool? isDeafened)

Parameters

voiceChannel SocketVoiceChannel

The voice channel that the user is currently in.

isMuted bool?

Whether the user is muted.

isDeafened bool?

Whether the user is deafened.

Fields

Default

Initializes a default SocketVoiceState with everything set to null or false.

public static readonly SocketVoiceState Default

Field Value

SocketVoiceState

Properties

IsDeafened

Gets a value that indicates whether this user is deafened by the guild.

public readonly bool? IsDeafened { get; }

Property Value

bool?

true if the user is deafened (i.e. not permitted to listen to or speak to others) by the guild; otherwise false; null if unknown.

IsMuted

Gets a value that indicates whether this user is muted (i.e. not permitted to speak via voice) by the guild.

public readonly bool? IsMuted { get; }

Property Value

bool?

true if this user is muted by the guild; otherwise false; null if unknown.

VoiceChannel

Gets the voice channel that the user is currently in; or null if none.

public readonly SocketVoiceChannel? VoiceChannel { get; }

Property Value

SocketVoiceChannel

Methods

ToString()

Gets the name of this voice channel.

public override string ToString()

Returns

string

A string that resolves to name of this voice channel; otherwise "Unknown".