mirror of
https://github.com/ION606/selmerBot.git
synced 2026-05-14 21:26:54 +00:00
20 lines
777 B
JavaScript
20 lines
777 B
JavaScript
|
|
const pathToFfmpeg = require('ffmpeg-static');
|
||
|
|
const { joinVoiceChannel } = require('@discordjs/voice');
|
||
|
|
const { generateDependencyReport } = require('@discordjs/voice');
|
||
|
|
const { VoiceConnectionStatus, AudioPlayerStatus } = require('@discordjs/voice');
|
||
|
|
|
||
|
|
module.exports = {
|
||
|
|
name: "playaudio",
|
||
|
|
execute(message, args, client) {
|
||
|
|
const channel = "930148609406685227";
|
||
|
|
//console.log(generateDependencyReport());
|
||
|
|
connection.on(VoiceConnectionStatus.Ready, (oldState, newState) => {
|
||
|
|
console.log('Connection is in the Ready state!');
|
||
|
|
});
|
||
|
|
const connection = joinVoiceChannel({
|
||
|
|
channelId: channel,
|
||
|
|
guildId: channel.guild,
|
||
|
|
adapterCreator: channel.guild.voiceAdapterCreator,
|
||
|
|
});
|
||
|
|
}
|
||
|
|
}
|