Help with discord js voice

arsb!ceval let mod = require("@discordjs/voice")
let player = mod.createAudioPlayer();
console.log(player)
mod.joinVoiceChannel({channelId: "1079420517523669133", guildId: message.guild.id, adapterCreator: message.guild.voiceAdapterCreator}).subscribe(player)
let gr = mod.createAudioResource("./Assets/tmp/song.mp3")
player.play(gr)
console.log(player)
arsb!ceval let mod = require("@discordjs/voice")
let player = mod.createAudioPlayer();
console.log(player)
mod.joinVoiceChannel({channelId: "1079420517523669133", guildId: message.guild.id, adapterCreator: message.guild.voiceAdapterCreator}).subscribe(player)
let gr = mod.createAudioResource("./Assets/tmp/song.mp3")
player.play(gr)
console.log(player)
uhh, here the audio thing is not playing, so heres the output from the debug stuff, In first console log, state is idle, In 2nd, its buffering, and this
_state: {
status: 'buffering',
resource: AudioResource {
playStream: [OggDemuxer],
edges: [Array],
metadata: null,
volume: undefined,
encoder: undefined,
audioPlayer: [Circular *1],
playbackDuration: 0,
started: false,
silencePaddingFrames: 5,
silenceRemaining: -1
},
_state: {
status: 'buffering',
resource: AudioResource {
playStream: [OggDemuxer],
edges: [Array],
metadata: null,
volume: undefined,
encoder: undefined,
audioPlayer: [Circular *1],
playbackDuration: 0,
started: false,
silencePaddingFrames: 5,
silenceRemaining: -1
},
2 Replies
d.js toolkit
d.js toolkit9mo ago
- What's your exact discord.js npm list discord.js and node node -v version? - Not a discord.js issue? Check out #other-js-ts. - Consider reading #how-to-get-help to improve your question! - Explain what exactly your issue is. - Post the full error stack trace, not just the top part! - Show your code! - Issue solved? Press the button! - Marked as resolved by OP
ProTon⚡
ProTon⚡9mo ago
├── @discordjs/voice@0.16.0 ├── discord.js@14.13.0 ├── ffmpeg-static@5.2.0 └── libsodium-wrappers@0.7.13 Nvm figured out it was the intents, didnt knew this needs the voice states intent