Code Monkey home page Code Monkey logo

discord_sync's Introduction

discord_sync

This is a Spigot plugin that will assign players a Discord role when they join the server.

Installation

You need Maven and a JDK installed.

Clone the repository:

$ git clone https://github.com/190n/discord_sync

Compile it:

$ cd discord_sync
$ mvn install

Then simply copy target/discord_sync-1.0-SNAPSHOT-jar-with-dependencies.jar into your plugins folder.

Configuration

The config file is stored in plugins/discord_sync/config.yml. It has the following properties:

Note: IDs for Discord things can be obtained easily by turning on "Developer Mode" under Discord's advanced settings. Then you you can right-click on a server, role, or user to get its ID.

roleId (string)

ID of the role that the bot should assign.

guildId (string)

ID of the guild (Discord server) in which the role should be assigned

players

Mapping of Minecraft user IDs (not usernames!) to Discord user IDs, both as strings. You can determine the UUID of a Minecraft account by entering its username at this website.

discordToken (string)

Token for a Discord bot account that the plugin should operate as. You must create an application here, add a bot to it, and add it to your server by following this guide. Make sure to give it the "Manage Roles" permission.

Example configuration (not with real IDs)

All the quotes are required, otherwise YAML will think they are numbers.

roleId: '8273648234'
guildId: '2346876'
players:
  e4a3c8e7-74ba-42fc-b6f1-aa0f52247ffb: '23746'
  7a1ee036-2852-4dd3-826b-93c0449e01bf: '28736'
discordToken: XXXXXXXXX

discord_sync's People

Contributors

190n avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.