Inspiration

We had the inspiration to learn and create a web application. With that as our first goal, we decided to build something that would have an impact. We thought about minor problems we had in our daily life and landed on a discord bot for clubs and activities on Discord. We realized that most discord bots are for general use and don't have much of a place in small Discord servers that are suited for clubs.

What it does

We have features that big Discord bots choose not to include for the sake of general use. Our bot has icebreaker commands such as coinflip, dadjoke, fight, magic8ball, and mindread. The command we found the most fun was mindread, which requires two players to guess what emoji the other would choose. Commands like magic8ball and coinflip are useful for settling debates. We also have interactive commands like hug, which simulates an actual hug through gifs. All of our commands have descriptions by using the command help on any Discord server the bot is in.

How we built it

We first went to Discord and built an empty bot. Then, we used node.js to run and manage the bot. Once we initialized the beginning files, we built the code that would log in as the Discord bot and take in messages from the server it was in. Whenever the code comes across a command in the chat, it runs the function that's related to the command. Since we didn't want to constantly run the bot locally, we transitioned to a Heroku server that would run the bot. There were also commands that required some data to be saved, so we used MongoDB, which would store our values in relation to users. We also needed to use an API for dad jokes because we didn't have infinite jokes on top of our heads.

Challenges we ran into

We had a lot of challenges regarding using databases, as it was the hardest to implement. We first tried using Sequelize, which was recommended for Discord bots, but it turned out to be really complicated and had a lack of resources. We moved onto MongoDB, which had more documentation and support. There were a lot of things we had to learn and get used to in order to use databases. We also had problems with using APIs. Learning and using Restless APIs proved to be really different from how we coded the Discord bot and came across multiple errors that were hard to decode. We spent the majority of our time figuring out how to manipulate databases and APIs but managed to learn from our endeavors.

Accomplishments that we're proud of

Like we said in the challenges section, we were able to use databases and APIs at a basic level. We took hours trying to read the documentation and understanding the code itself. In the end, we were able to communicate with the database we created as well as communicate with the dad jokes API.

What we learned

We learned how simple Discord made it to create a bot, with really intuitive tutorials and helpful libraries. When it came to more advanced techniques, we had to spend more time trying to decipher what the documentation meant. However, our experience taught us to understand foreign frameworks more intuitively.

What's next for Dachi Bot

We're hoping to create a currency system that would specialize in club usage and participation. We hope that this feature would accelerate the productivity and utility of the bot, especially since most clubs are, whether they like it or not, using Discord to communicate in a virtual environment.

Built With

Share this project:

Updates