A JDA bot to reply to user-defined phrases (e.g. "im crying")
Command | Description |
---|---|
/trigger new |
Adds new trigger |
/trigger reset |
Resets all stored triggers |
/trigger list |
Lists all stored triggers |
/trigger delete |
Deletes specified trigger |
/trigger toggle |
Toggles trigger feature |
- Go to the Discord Developer Dashboard
- Register your bot
- Enable Server Members Intent and Message Content Intent
NOTE: We highly recommend using IntelliJ IDEA for development.
- Clone the repository
- Create a
.env
file in the main directory (copy the template provided in .env.example): - Specify Corretto 18 as the project SDK
- Download Maven Code Style
- Restart IDE
-
Build the project
python3 build.py
-
Run the project
java -jar triggers.jar
-
To invite your bot, use the following link:
https://discord.com/api/oauth2/authorize?client_id=$DISCORD_CLIENT_ID&permissions=66560&scope=bot%20applications.commands
and replace
$DISCORD_CLIENT_ID
with the bot ID
- Create a new branch
- Make your changes
- Make sure Maven is set as the current Code Style Scheme
- Reformat code with
Ctrl + Alt + L
- Create a pull request
-
"I can't invite my bot"
- Make sure you have the correct permissions (66560)
- Make sure you have the correct scope (bot%20applications.commands)
- Make sure you have the correct client ID
-
"I can't run the bot"
- Make sure you have the correct token
- Make sure you have the correct role IDs
- Make sure you have the correct JDK version
-
"How do I get my bot ID?"
- Go to Discord Developer Dashboard → Your bot → General Information → Application ID
-
"How do I get my bot token?"
- Go to Discord Developer Dashboard → Your bot → Bot → Token → Copy
-
"Why does the bot not respond to my messages?"
- Make sure you have the correct role IDs
-
"How can I get my role ID?"
- Go to your server → Server Settings → Roles
- Right-click on the role you want to get the ID of and select "Copy ID"
-
"It says 'Class has been compiled by a more recent version of the Java Environment' when I try to run the bot"
- Make sure you have the correct JDK version. Download JDK 19 here.
Created with 💖 by acmcsuf.com com.acmcsuf.bot_committee