Skip to content
zeroclutch edited this page Apr 16, 2020 · 1 revision

Gamebot

About

Gamebot is a bot for Discord, a popular social media platform focused on gaming.

See the README for more information about this bot and its features.

Creating a Game

If you want to contribute to Gamebot by developing a game, you need to get your very own copy of Gamebot.

Warning ⚠️: This doesn’t work yet! Gamebot depends on a MongoDB server and the bot won’t run if it doesn’t have that server linked. In a coming update, this dependency won’t be required for gamr development.

First, you should clone this repository. Then open it using cd gamebot.

git clone https://github.com/zeroclutch/gamebot.git
cd gamebot

Next, you’ll need to install Node.js. The latest version of Gamebot is compatible with v10 of Node.js. You should use nvm to manage multiple versions of Node.

Node.js v10.18.0 Recommended for Gamebot Node.js latest release Not recommended - will run into errors

After that, you will have to create your own Discord bot account. Use this straightforward guide by discord.py. You should also add your bot to a server.

Once you have your account, you’ll need to make an environment variables file so your bot can log in. Create a new file in your working directory and name it .env. Paste this into your .env file:

DISCORD_BOT_TOKEN=YOUR_TOKEN_HERE
OWNER_ID=YOUR_DISCORD_ID_HERE
PREFIX=&

Replace YOUR_TOKEN_HERE with the token you got from the Discord Developer Portal in the linked guide above. Your token should look something like NzAwMjY2KDM4MDxdADMDNzZz.X0pgcjA.zDtrqfmQa5J-abcdefGh123Ijklmn.

Also, replace YOUR_DISCORD_ID_HERE with your Discord ID. If you don’t know how to get your ID, see this article.

Now in your command line, you should install dependencies and run the bot.

npm install
npm run start

Ta-da! You probably got an error. I’ll fix that soon.

Clone this wiki locally