Chris Rhodes 290da20da7 Add a new example that acts like airhorn.solutions | před 8 roky | |
---|---|---|
.. | ||
README.md | před 8 roky | |
airhorn.dca | před 8 roky | |
main.go | před 8 roky |
This example demonstrates how to utilize DiscordGo to listen to an !airhorn command in a channel and play a sound to that users current voice channel.
This assumes you already have a working Go environment setup and that DiscordGo is correctly installed on your system.
go install github.com/bwmarrin/discordgo/examples/airhorn
cd $GOPATH/bin
cp ../src/github.com/bwmarrin/discordgo/examples/airhorn/airhorn.dca .
Usage of ./airhorn:
-t string
Account Token
The below example shows how to start the bot.
./airhorn -t <bot token>
Airhorn bot uses DCA files that are pre-computed files that are easy to send to Discord.
If you would like to create your own DCA files, please use https://github.com/bwmarrin/dca/tree/master/cmd/dca.
./dca -i <input wav file> -raw > <output file>