Skip to content

Latest commit

 

History

10 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Discord Study Bot

How to Run the Source Code

(Note: You should have Java already running on your machine)

  1. Create a new Discord application [[https://discord.com/developers/applications]]

  2. In General Information, look for the Application ID and click copy.

  3. In the following link, replace YOUR_APPLICATION_ID with the application ID of your bot. Then open the link and add it to your server.

https://discord.com/oauth2/authorize?client_id=YOUR_APPLICATION_ID&permissions=8&integration_type=0&scope=bot+applications.commands

  1. Generate a Discord bot token on the Bot page, by clicking Reset Token.

  2. Create a file called discord.secret in the root directory (sibling to this README.md file), and paste that token there.

  3. Run chmox +x gradlew to make gradlew executable (macOS/linux)

  4. You should be able to run ./gradlew run in a terminal inside the root directory of this project.

  5. After the bot loads into your server, force quit and reopen discord to make sure the slash commands load.

  6. You should be able to use the bot's slash commands.

Source Code Structure

/
    /app/src/main/java/discord/bot
        /commands
            Contains all command files, which are triggered
            to handle bot interaction events

        /data
            Contains DataStore, which manages all data,
            as well as multiple DataClasses,
            which can be saved to the database.

            DataStore.Java
            DataClass.Java

            (Data stored with Discord IDs)
            UserData.java
            MessageData.java

            (Custom data)
            Flashcard.java
            FlashcardDeck.java
            StudySession.java

        /managers 
            BaseManager.java
            SlashCommandManager.java

        App.java — Entrypoint
    data.json — Automatically created by DataStore
    discord.token — Manually created (contains Bot token)

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages