Search code examples
c#dllopusdiscorddiscord.net

C# Discord.NET Error joining voice channel


Trying to set up a discord bot to join a server and when using a try catch statement I get the following output in console:

Unable to load DLL 'opus'

Any ideas on how to fix?

I'm assuming I have to go to https://opus-codec.org/downloads/ and download the opus codec?

-

Thanks


Solution

  • You needed to download the opus.dll and place it in the same file as the executable. The download can be found here: https://github.com/RogueException/Discord.Net/blob/master/src/Discord.Net.Audio/opus.dll

    If you have any other issues setting up the bot, read the documentation: http://rtd.discord.foxbot.me/en/legacy/features/voice.html