A Discord bot that lets users play with a standard 52-card deck of playing cards.
Drawing cards and changing the art style
Playing a game of High or Low
This bot gives Discord servers a deck of playing cards that anyone in the server can use. You can draw cards, shuffle the deck, change the art style of the cards, and play a game of High or Low with others.
I've been using Discord for 4 years now, and seeing all the different kinds of bots out there made me want to try making my own. I've also been interested in learning Go for a while now, so making a Discord bot with Go seemed like a great project idea for me to learn from, and this hackathon was a good opportunity to do so.
The frontend is a simple, responsive landing page showing the bot's features and commands along with a button to add the bot to your own Discord servers. I used HTML and CSS only.
The backend consists of the bot itself and the standard Go packages for hosting card images and the frontend website. I used the DiscordGo package for the bot, which provides Go bindings for the Discord API.
Since this was my first time using Go but not my first time making an app, I mainly had to learn language-specific things, like how to set up a Go project, how to use the
net/http package to serve files, and how to use goroutines to run multiple card games at a time. The DigitalOcean App Platform made the deployment process much easier for me because I didn't have to worry about building the app and figuring out how to run the build as a service on a Linux server.
The two card image sets used are CC0 licensed (public domain) and come from Kenney. You can find them here: