CameronSWilliamson / MinecraftDiscordChat

A Spigot plugin that uses player position to assign them to voice channels

Home Page:https://CameronSWilliamson.github.io/MinecraftDiscordChat

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Contributors Forks Stargazers Issues MIT License LinkedIn


Minecraft Discord Chat

A Spigot plugin with a focus on Discord integration.
Explore the docs »

View Demo · Report Bug · Request Feature

Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. Contributing
  5. Dev Tools
  6. License
  7. Contact
  8. Acknowledgments

About The Project

This Spigot server plugin unifies the world of Minecraft with the complexities of a Discord server. Users can create areas in specific Minecraft servers that link to a Discord voice channel. When players enter a new area in-game, they are moved to the corresponding voice channel and return to the default voice channel after exiting. In addition, user’s chat messages in Minecraft are redirected to a discord text channel and vice versa. This allows for a more immersive and seamless experience for users of the server.

Version 1.0.0 of this plugin was created during the 2022 Gonzaga University Hackathon and was written in less than 12 hours. It did not earn any awards but most of the competitors thought it was a super cool idea.

(back to top)

Getting Started

To get a local copy up and running follow these simple example steps.

Prerequisites

  • Java 17
  • Gradle (from source)
  • Minecraft 1.19+

Installation

  1. Set up a Discord Bot at https://discord.com/developers/applications and invite it to your server. Save your tokenID from the api to put in the config file.

  2. Create a spigot server. This can be done by running the following bash commands or by downloading the server from https://www.spigotmc.org/

    mkdir -p minecraft_server/build
    cd minecraft_server/build
    curl https://hub.spigotmc.org/jenkins/job/BuildTools/lastSuccessfulBuild/artifact/target/BuildTools.jar -o BuildTools.jar
    java -jar BuildTools.jar
    mv spigot-*.jar ../spigot.jar
    cd ..
    rm -rf build
    echo eula=true > eula.txt
  3. Either clone this repo and build from source or download the latest release from Releases

  4. Place this file in minecraft_server/plugins/ and open minecraft_server/plugins/MinecraftDiscordChat/config.yml and fill in the required fields:

    api_token: "YOUR_Discord_BOT_TOKEN"
    default_category_name: "The name of the Discord category to use"
    default_server_id: "The server ID of the Discord server to use"
    # The following are optional
    default_text_channel_id: "The default text channel ID to use"
    default_voice_channel_id: "The default voice channel ID to use"
  5. Run your minecraft server by running java -jar spigot.jar in minecraft_server/ and join the voice channel you specified in the config file. You should see a message in the console saying that the plugin has been enabled.

(back to top)

Build From Source

  1. Clone the repo

    git clone https://github.com/CameronSWilliamson/MinecraftDiscordChat.git
  2. Build the jar file

    make compile
  3. Copy the jar file to your minecraft server

     cp build/libs/MinecraftDiscordChat.jar /path/to/minecraft/server/plugins/

Usage

Getting started with the plugin is easy.

  • Join the minecraft server and run /discord <username>#<numbers> to link your minecraft username to your Discord username.
  • In the Minecraft server you can run /createvoice <area name> to recieve a stick named "AreaDefiner <area name>". Right click in one corner of the area you want to define as a voice area and then right click in the opposite corner. This will create a voice area with the name you specified linked to a new voice channel in Discord that players will be moved to when they enter the voice area.
  • In the Minecraft server you can run /deletevoice <area name> to delete the voice area with the name you specified.
  • In the Minecraft server you can also run /request <feature/bug> to request a feature or report a bug. This will send a mesage to the developer of the plugin on Discord.

(back to top)

Contributing

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

  1. Fork the Project
  2. Create your Feature Branch off of the dev branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

(back to top)

Dev Tools

Many development tools are included in the Makefile to make development easier. These include:

  • make compile - Compiles the plugin into a jar file
  • make clean - Cleans the build directory and removes the test server
  • make spigot - Downloads the latest spigot server jar file and runs spigot build tools
  • make run - Runs the plugin in a test server
  • make doc - Generates javadoc for the plugin
  • make rmdb - Removes the database file for the test server
  • make cleanrun - Cleans the build directory, removes the test server, and runs the plugin in a test server

License

Distributed under the MIT License. See LICENSE for more information.

(back to top)

Contact

Cameron Williamson - @therealkeyisme - therealkey@outlook.com

Project Link: https://github.com/CameronSWilliamson/MinecraftDiscordChat

(back to top)

About

A Spigot plugin that uses player position to assign them to voice channels

https://CameronSWilliamson.github.io/MinecraftDiscordChat

License:MIT License


Languages

Language:Java 97.5%Language:Shell 1.3%Language:Makefile 1.1%