Closed deluvas1911 closed 3 years ago
When the player is moved to the ingame channel, the plugin already sends the sound state. Idk why you would think that it doesn't...
I seriously don't know what the heck went wrong, because when I tested my code and created this issue this hasn't worked. After trying now again it correctly sets the state on login.
This time I also got the correct entries in my ts3client log: 2021-02-07 08:55:42.077077|DEBUG |Salty Chat |12 |{"Command":6,"ServerUniqueIdentifier":"naJ1/+DsaolvDwTm7qSTlRiGeKw=","Parameter":{"IsMicrophoneMuted":true,"IsMicrophoneEnabled":true,"IsSoundMuted":false,"IsSoundEnabled":true}}
The issue I had with the prior tests was also that IsSoundEnabled and IsMicrophoneEnabled been stuck at false until I opened a 2nd teamspeak connection and toggled my mic there. Today everything seems to work fine.
As far as I have seen there is no possibility to get the SoundState on connect.
If a player joins the server while being muted, I have to assume he is not muted. If he's muted there is neither in the Initiate nor the InstanceState events data about his sound state. Adding those data to the Initiate (or at least manually triggering the SoundState after being moved to the ingame channel, which would have better compatibility with most of the scripts out here) would allow the servers to update the UI on connection to the correct state already.
Thanks