Skip to content

yanis-dlmr/resistance-fr

Repository files navigation

icon Resistance FR - Discord Bot

Linux Windows GitHub license GitHub commits GitHub latest commit Maintenance

Python Package GitHub release Author Author

  1. ✏️ In short
  2. 👩‍🏫 Usage & Setup
  3. 💁 Get Help
  4. 🔰 Support
  5. 🧪 Testing
  6. 🧑‍🏫 Contributing
  7. ⚖️ License
  8. 🖼️ Icons
  9. 🔄 Changelog
  10. 🐛 Bugs and TODO

✏️ In short

This is the discord bot of the unofficial Black Desert Mobile French community driven Discord Server. This bot only accepts slash commands and apps commands, and is written in Python 3.11.

Note

Please note that we, the developers, are not affiliated with Pearl Abyss in any way. This bot is a community project, and is not officially supported by Pearl Abyss.

To begin, create an .env file in the root directory of the project following the .env.example file (all fields required) :

BOT_ID = 1000490579291017337
BOT_PREFIX = "$"
BOT_TOKEN = 
BOT_INVITE = "https://discord.com/oauth2/authorize?client_id=1000490579291017337&scope=bot&permissions="

DB_USER = 
DB_PASSWD = 
DB_URL = 
DB_PORT = 27017

DEBUG = False

👩‍🏫 Usage & Setup

Info

Please note we do not officially support Windows or MacOS, but we do provide some instructions for those who want to use it on these platforms.

You do not explicitly need a conda environment for the bot to run. But it is always recommended nontheless, especially because the next LTS of Ubuntu won't let users pip-install anything without a virtual environment. At the time of writing, this bot requires python >= 3.10 to run.

# Clone the repository
git clone https://github.com/yanis-dlmr/resistance-fr.git
cd resistance-fr

You can create and activate a conda environment with the following commands :

# Creates environment and install dependencies
conda env create -f environment.yml -y
conda activate dsc

Finally, run the bot in the background with nohup :

# Runs the bot in the background
nohup python resistance-fr.py &
# pkill -U $USER -f resistance-fr # to kill the bot

or in the foreground :

# Runs the bot (lets you Ctrl+C to stop it)
python resistance-fr.py

💁 Get Help

Inside the Discord app, you can type

/<GroupName> help

to get help about a specific group of commands. For example, you can type /utils help to get help about the utils group of commands.

You can try to ping the bot in your guild to start 👋 :

/utils ping

🔰 Support

Contact us on Discord :

  • blcklight#0
  • yanisdlmr#0

➕ Create a new Issue

🧪 Testing

Oh god ... please don't. Still, make sure you have everything installed, and run the following :

python -m pytest
python -m pylint src
python -m yapf -dr src

🧑‍🏫 Contributing

If you ever want to contribute, either request the contributor status, or, more manually, fork the repo and make a full request !. On a more generic note, please do respect the Python Coding Conventions and wait for your PR to be reviewed. Make sure you respect and read the Contributing Guidelines, make pull requests and be kind.

The standard procedure is :

fork -> git branch -> push -> pull request

Note that we won't accept any PR :

  • that does not follow our Contributing Guidelines
  • that is not sufficiently commented or isn't well formated
  • without any proper test suite
  • with a failing or incomplete test suite

Happy coding ! 🙂

⚖️ License

This project is licensed under the AGPL-3.0 new or revised license. Please read the LICENSE file. Additionally :

  • Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.

  • Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.

  • Neither the name of the Resistance FR authors nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

Resistance FR - Discord Bot
Copyright (C) 2023 Thomas BOUYER & Yanis DELAMARE

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.

🖼️ Icons

Icons (except the logo(s)) are made by Freepik and pixelmeetup from www.flaticon.com.

Unless otherwise stated, all icons and logos are made by the authors. Copyright (C) 2023 Thomas BOUYER, Yanis DELAMARE, all rights reserved.

Tools used :

🔄 Changelog

Please read the changelog file for the full history !

First Beta Dev Release (click here to expand)

v0.1 send help ?

  • fork of Useful Moderator
  • added xp group of commands
  • added all legal and github related stuff
  • polls are now working 🎉 !
  • added global app commands error handler
  • dispatcher and embed_builder are now in their own classes
  • logger is now globally setup and each class creates its own logger

v0.2 events and cie.

  • events are loaded and the config is reloaded on each valid event

🐛 Bugs and TODO

TODO (first implementation version)

  • MongoDB integration
  • polls, auto responses and reactions, ...
  • xp and level up mechanism
  • creates events for other bots
  • poll events from MongoDB
  • guide on how to setup MongoDB database for this bot (@yanis-dlmr 🥲)
  • ...

Known Bugs (latest fix)

  • bot timer may be delayed by 7 or 8 seconds

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published