adriansteffan / DiscordJockey

A lightweight Discord music bot written in Python.
GNU General Public License v3.0
41 stars 14 forks source link
bot currently-broken discord discord-bot discord-py music python

DiscordJockey

DiscordJockey is an open source, lightweight musicbot for Discord. It was written in python using Discord.py. It can stream music from sites like youtube straight to your Discord voice channels and helps you create a more chill atmosphere while enjoying your favourite games.

This bot is somewhat outdated and could therefore not function as intended. Fixing it is on my backlog, so do not worry :)

Getting Started

(To learn more about the features of DiscordJockey, type !help in your serverchat or read the documentation below.)

I am no longer hosting this bot as I am working on an improved version with a whole lot more features. Also, some features could break by changes being made to the official repo of discord.py in the future, so be aware of that.

If you want to run the bot on your local machine or a server, see the instructions below.

Prerequisites

You need to have a version of python 3.5+ installed on your machine. If you are windows, make sure that the executable is added to PATH. How to do it on Windows 10

You also need the newest versions of aiohttp, youtube-dl and bs4, as well as the rewrite version of Discord.py. To install those, simply us ethe following pip command

pip install -U aiohttp youtube-dl bs4 git+https://github.com/Rapptz/discord.py@rewrite#egg=discord.py[voice]

On Linux, you might also need to install some additional packages:

apt-get install libffi-dev libnacl-dev python3-dev ffmpeg

Installing - Hosting the bot yourself

The setup is really straight forward. First, you need to create a new application here and turn it into a Bot-User via the "Add" button on the "Bot" menu. Next, you need to add the bot to your server. Here is a simple explanation on how to do that. Now you need to reveal and copy the token of the bot.

At last, you need to download this repository, copy it to wherever you like, insert the token at the top of the "config/config.py" file (save it) and run the startup.bat or startup.sh script, based on you OS. Alternatively, you can also run the run.py script with python via your console from the root directory of the project.

The bot should join you server automatically.

Usage

After the bot has joined your server, you can pm him !help or write it in a textchannel to get an overview of the available commands. At the moment, the following commands are supported:

!connect [channel (optional)]
!disconnect
!cc [channel]
!addbot
!yt [link/video title/key words/playlist-link]
!spotify [nickname (optional)]
!pause
!resume
!stop
!skip
!prev
!vol [volume in %]
!songinfo
!history

Authors

License

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

Acknowledgments

Shoutout to the community over at the Discord-API Discord servers, who gave me a helping hand when the Rewrite library gave me headaches.