The goal is for this to be a multipurpose bot for Paints & Shells! Current functionality:
- Art Fight: "attack" another member by drawing their OC or something for them to get activity points.
Open for anyone to contribute to.
-
If you don’t have Python installed, install it from here.
-
Clone this repository.
-
Navigate into the
Shellsproject directory:cd Shells -
Create a new virtual environment:
python -m venv venv source venv/bin/activatepython -m venv venv venv/Scripts/activate
-
Install the requirements:
pip install -r requirements.txt
-
Make an environment variables file (
.env) You should still be in theShellsdirectory:touch .env
-
Fill in the
.envfile with the following:DISCORD_TOKEN=your_discord_bot_token FIREBASE_DATABASE_URL=your_firebase_database_url FIREBASE_KEY=firebase_key.json
- Replace
your_discord_bot_tokenwith your bot's token. - Replace
your_firebase_database_urlwith your Firebase database URL. - Replace
firebase_key.jsonwith the path to your Firebase key file.
- Replace
-
You'll need to create a discord bot and invite it to your server.
-
To turn on Presence Intents, go to your bot's settings,
Bot -> Privileged Gateway Intents, and turn on all 3 Presence Intents. -
Fill in the .env file with your bot token.
- Once your bot has joined your server, be sure to give it a role with permissions to "Manage Messages"
-
Create a Firebase project
-
Go to
Build -> Realtime Databaseand create a database, copy the link you see (ie.https://example.firebaseio.com). Save this to your .env file asFIREBASE_DATABASE_URL -
Go to
Project Settings -> ⚙️ -> Service Accounts -> Generate New Private Keyand download the JSON file asfirebase_key.json. -
Drag the downloaded file into this directory.
-
Set FIREBASE_KEY in your .env to the path of this key.
- Is your test database public? Check in Realtime Database > Rules
Run the app using python or python3 depending on your system (make sure you are in the Shells/src directory):
cd src
python main.pyDesigned around a single server.
.
├── "attacks"
│ └── Attack's Discord Message ID
│ ├── "attacker"
│ ├── "victim"
│ ├── "points"
│ ├── "message"
│ ├── "size"
│ ├── "finish"
│ ├── "color"
│ ├── "shading"
│ └── "background"
└── "users"
└── User's Discord ID
├── "name"
├── "points"
├── "oclink"
├── "notes"
├── "attacks_sent"
│ └── [List of attack IDs]
└── "attacks_received"
└── [List of attack IDs]