SpaceManiac / discord-rs

Rust library for the Discord chat client API
MIT License
385 stars 94 forks source link

Get voice of single players and connect multiple time #171

Closed Tockra closed 1 year ago

Tockra commented 2 years ago

Hi,

I wanted to ask, if it is possible with this crate to get the voice of single players and record / process it seperatly. Further I wanted to ask if it is possible to join with multiple users (with not fixed names) to the voice chat of a single server.

I know something like that works with other voice clients like teamspeak, but I have no idea if it is possible with discord (because of the bot-token system).

T

SpaceManiac commented 2 years ago
  1. Yes. AudioReceiver::speaking_update can be used to learn the ssrc to UserId mapping, and AudioReceiver::voice_packet includes an ssrc argument.
  2. Only by using multiple bot accounts.
Tockra commented 2 years ago

Okay thank you. 2. seems to be a blocker for my project. Is it possible to add e.t. 100 bot accounts and change their names while using them (with your crate) ? Or are the names static?

SpaceManiac commented 2 years ago

The Discord::edit_profile method can be used to change a bot's username, and there is also the option of changing its nickname within a single server. But 100 bot accounts is a lot. I suspect Discord staff might consider this abuse. I can't do anything to help you if that happens.