discord-music-and-radio-bot

Yet another open source Discord bot using discord-player and discord.js.

Warning, this code uses the v12 of the Discord.js module. Previous versions of discord.js will not be supported.

Issues

If you have any issue feel free to make a new issue here.

Installation

Use the package manager npm to install all the packages. Using npm install, will automatically install all the package needed. Make sure your node version is not below 12.

Configuration

Start by editing the Config/botconfig.json file:

{
  "prefix":"Your Bot Prefix",
  "embed":"Hex Colour",
  "error":"Hex Colour",
  "owner":["Your ID"]
}

Please do not mess with the config.json file inside the Config folder.

After you have finished editing the botconfig.json file, edit the .env file:

token=YOUR_TOKEN_HERE

Reminder:

Commands

Utilities

Functions available with the discord-player module that you can use :

// Play a song in the voice channel and init the guild queue
client.player.play(voiceChannel, songName);

// Add a song to the queue
client.player.addToQueue(guildID, songName);
// Clear the queue
client.player.clearQueue(guildID);
// Get the queue
client.player.getQueue(guildID);
// Skip the current song
client.player.skip(guildID);

// Pause
client.player.pause(guildID);
// Resume
client.player.resume(guildID);
// Stop
client.player.stop(guildID);

// Check if music is playing in a guild
client.player.isPlaying(guildID);
// Get the currently playing song
client.player.nowPlaying(guildID);

// Current song will be repeated indefinitely
client.player.setRepeatMode(true);
// Current song will no longer be repeated indefinitely
client.player.setRepeatMode(false);

License

MIT

Acknowledgements & Thank Yous

I <3 Open Source, so I'd like to acknowledge the brilliant packages making this repository happen.

These are the open source libraries I use to make this bot:

Thank you to:

I used both of your repositories as a help guide for making this repository, hope you don't mind guys.