Today I walk you through the step by step process of building your own Discord Music Bot from scratch. We cover a variety of different commands and features including
- a play command that can load single songs, playlists, or search generally from the internet.
- a paginated queue command
- pause/resume commands
- info command with a progress bar
npm packages installation
npm i dotenv discord.js discord-player @discordjs/voice @discordjs/rest @discordjs/opus @discordjs/builders
You will also need to install ffmpeg in order for the bot to stream music. Find the relevant information here: ffmpeg.org/download.html
Timestamps
0:00 Intro
0:50 Setup code environment
1:28 Start coding the bot
4:32 Slash command file loader
7:45 Deploying Slash commands
9:58 Slash command handler
12:31 /play
24:59 /queue
33:54 /quit
35:38 /shuffle
36:32 /info
38:43 /resume /pause
39:52 /skip
41:07 /skipto
43:35 Demo
46:20 Outro
🔗 Links
Source Code: github.com/3chospirits/discord-music-bot/tree/a260d1eb43a974ea232c603c93b0e1f40647ae68
Discord Server: discord.niconiconii.xyz
21 фев 2022