Closed sambeyer closed 8 years ago
ENOENT
is an abbreviation for Error no ENTry. In other words your path is faulty. Either give it an absolute path C:/Users/sambeyer/Documents/projects/DiscordBots/SoundCloudBot/intro.wav
or the path relative to your root, so if you execute your file in /SoundCloudBot/youfile.js
the relative path to intro would simply be intro.wav
Hey, thanks for your help, I was wondering what ENOENT meant.
Unfortunately I'm still having the same issue having tried using both the absolute path and the relative path.
I'm guessing it's not finding ffmpeg then. Follow the steps posted here https://github.com/hydrabolt/discord.js/issues/415
That fixed it!! I hadn't installed it properly.
I'm still having issues, as I've edited above. Now just no sound is playing.
All voice-related problems should be resolved if you followed the mentioned steps and your code is correct.
Again, to check if you did everything properly..:
1.) Go to your console and type ffmpeg -version
. Does it recognize ffmpeg?
2.) Go to your console and type python --version
Everything above 2.x.x is not supported
3.) Go to your project folder and reinstall discord.js. Do you get any errors? node-gyp
errors are related to missing C++ build tools.
4.) If all this doesn't fail and you still don't get sound make sure your bot has permissions to speak and is not muted.
That's fixed it!! Than you so much!
I installed the appropriate version of Python as suggested.
The problem persisted and as you suggested I reinstalled discord.js and found it was giving node-gyp errors as predicted. In an effort to fix these I started using Visual Studio 2015. There were fixes using Visual Studio I found for each error encountered. The bot works perfectly now!!
Again thanks heaps, I'm absolutely stoked.
Hi,
I'm trying to get my bot to play audio, however regardless of which play function it uses, my code breaks. Currently I have:
bot.voiceConnection.playFile("Documents/projects/DiscordBots/SoundCloudBot/intro.wav", {volume:0.25});
I've also tried using code found here (using both playRawStream and playFile). The same error occurs.
Here's the error:
EDIT: The problem was I hadn't installed ffmpeg properly. I don't get that error anymore.
However the problem persists in a different form. I still can't get anything to play. Everything else happens which should, apart from the bot actually playing anything.