Suggestion: Filter out sounds from other bots
lmmfranco opened this issue · 2 comments
Having a music/sound bot in the same channel can spam the speech recognition with useless requests. Would be nice to have a setting (or even by default) to ignore messages from bots.
You can make a pull request for this feature. Basically add checking if user is a bot in handleSpeechEvent (of course it's only my suggestion, you can figure out something by yourself)
How to check if user is a bot?
client.users.cache.get(userId).bot // returns true when user is a bot
To add another options to bot modify this interface:
discord-speech-recognition/src/bot/speechOptions.ts
Lines 13 to 21 in f5858d7
Here you can specify default options:
discord-speech-recognition/src/bot/addSpeechEvent.ts
Lines 22 to 26 in f5858d7
I will be more than happy to review your PR and also by contributing to this repository you will get a chance to win a t-shirt in hacktoberfest event - read more here https://hacktoberfest.digitalocean.com/