Move our own state out of TeamspeakConnection: OwnClient, Recording
OwnClient owns the microphone and speakers and our flags (mute, deafen, away, commander, talk request, phonetic nickname, input hardware) and publishes them; Recording owns the recorder. ServerSession reads the flags from OwnClient instead of keeping its own copy, and they are now cleared when a connect starts rather than once it is done. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -105,8 +105,8 @@ class ServerController internal constructor(
|
||||
|
||||
val isConnected: Boolean get() = session.isConnected
|
||||
internal val isBusy: Boolean get() = session.isBusy || network.isRecovering
|
||||
internal val microphone get() = if (session.isConnected) conn.microphone else null
|
||||
internal val playback get() = if (session.isConnected) conn.playback else null
|
||||
internal val microphone get() = if (session.isConnected) conn.ownClient().microphone() else null
|
||||
internal val playback get() = if (session.isConnected) conn.ownClient().playback() else null
|
||||
|
||||
/** Not on the server and not trying to get back on it: done with. */
|
||||
internal val ended: Boolean get() = started && !isBusy
|
||||
|
||||
Reference in New Issue
Block a user