https://github.com/jojofr1/joseta
A Discord bot made in Java with the JDA library.
https://github.com/jojofr1/joseta
discord-bot java jda
Last synced: 11 months ago
JSON representation
A Discord bot made in Java with the JDA library.
- Host: GitHub
- URL: https://github.com/jojofr1/joseta
- Owner: JojoFR1
- Created: 2024-11-15T18:03:35.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-12-13T23:43:33.000Z (over 1 year ago)
- Last Synced: 2024-12-14T00:26:45.954Z (over 1 year ago)
- Topics: discord-bot, java, jda
- Language: Java
- Homepage:
- Size: 277 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Joseta

## Project
Joseta is a multipurpose, single server, Discord bot made with the [JDA](https://github.com/discord-jda/JDA) library.
### Why single server?
This bot original purpose is to only be used in the official [Mindustry France](https://discord.com/invite/hzGPWhZSGV) Discord server only - so it was made without any plans to support multiple servers nor to be a public bot for now, this could change in the future. Features are only implemented based of our needs.
This bot is not *yet* fully usable for personal use due to multiple hardcoded values that are mostly now removed with the configuration command. If you wish to use it you are free to do so buy we do not give any support as of now.
### Why Java and JDA?
We could have used JavaScript or Python or literally any other languages, but due to personal preferences we have chosen Java and the JDA library as it was a library we already had experience with. Discussion for a possible Kotlin transition will be explored.
## Features
This is a multipurpose bot and is not centered around one specific category or idea, all features implemented (updated or removed) are based only on our needs. See below for a list of all the features this bot currently has:
- An **Image-based Welcome** for new members (or message in case the image is disabled or not properly loaded).
- A **Goodbye Message** for leaving members.
- A **Counting Channel** to count until infinity.
- **Rules** + an **Acceptation System**, acting as verification too (not *yet* configurable).
- An **Auto Response** for common questions (not *yet* configurable but can be disabled).
- A **Counting Channel** to let users count until infinity.
- Multiple commands:
| Category | Commands | Use |
|:-----------|:---------------|:--------------------------------------------------------------------|
| Admin | `/admin` | Admin related commands (rules, counting managing). |
| | `/config` | Configure the bot variables for your server. |
| Misc. | `/ping` | Get the bot and Discord API ping in milliseconds. |
| | `/multi` | Manually send the multiplayer help message. |
| | `/markov` | Generate a pseudo-random message using messages sent on the server. |
| | `/reminder` | Add or list reminders. |
| Moderation | `/modlog` | Get a member current moderation history. |
| | `/(un)ban` | (Un)Ban a member from the server. |
| | `/kick` | Kick a member from the server. |
| | `/(un)timeout` | (Un)Timeout a member on the server. |
| | `/(un)warn` | (Un)Warn a member on the server. |
| | `/clear` | Clear messages in the channel. |
## Plans
The current plans and ideas for this bot are the following, in the likely order in which they will be made:
- Message leaderboard + levels (?).
- Rework config command to use embed instead of multiple arguments command
- Add translation for messages & logging (mainly to lower string repetitions and to have it all in one file)
- Refactor the Event system
- Could do like one single global `ListenerAdapter` and add in the appropriate event the function we want to execute
- Maybe use annotations system (could do the same for commands)
- Other implementations could be explored (but I do not have any idea for now)
- Add a Logging system (currently on pause, see [PR #6](https://github.com/JojoFR1/Joseta/pull/6)):
- Log the warns of the bot.
- Support multi-server:
- Mainly to make it usable outside our server.
- Make it actually usable for others.
## How to build
Building requires **JDK 17** or later.
At the root of the project, use the following command:
`./gradlew shadowJar`
Once the build process is finished, the output will be present in `./build/libs/JosetaBot.jar`.
## How to run
You will first need to follow the instructions in the `secret_template.cfg` file before being able to run the bot.
After this, starting the bot is very easy. You need to execute this command: `java -jar build/libs/JosetaBot.jar`
The following arguments (after the `.jar`) are available to use:
- Default: run the bot normally. (Log level is info level)
- `--debug`: run the bot in debug mode. (Log level is debug level & intended for testing)
- `--server`: run the bot in server mode. (Log level is debug level & save log file up to 7 days)
## Contributors
Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/docs/en/emoji-key)):

Jojo
💻 🤔 🚧

ZetaMap
💻

Patou
💻

l4p1n (Mathias B.)
💻 🤔 🧑🏫 🚇
Add your contributions
This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!