Documentation


About

Discraft is a bot/plugin that enables Discord admins to run commands on their Minecraft Server from Discord. One of the main features of this bot, is that discord members in your server (once given a specific role), can add themselves to your whitelisted Minecraft Server without a mod having to intervene and add them manually.

This is ideal for Discord communities who only want "Patreons" to be able to join their whitelisted server.

It is all a work in progress though, so if you find any issues please file a bug report. If you have any questions or suggestions feel free to add me on Discord: BurntWindow#3499

Use /setup for information on how to setup the bot in discord or /help for command help.


Setup

Firstly, download and install the latest release of Discraft from here, and put it into your plugins folder on your Minecraft server.

Then invite the bot click here to your server.

To configure the bot, visit the Dashboard

Then do /auth to get the authkey for your server. This will be sent to you via DM, keep this secure! (Auth Key on the Dashboard)

Then once you've started the Minecraft Server copy the authkey into the authkey field in the config.yml within plugins\discraft or into /discraft auth <authkey> on the Minecraft server.

Then (on the Minecraft server), run /discraft link to link the minecraft server to the discord bot.

By default you have to manually link the server to the bot every time your server IP changes. This is fine for most servers but some people may need to link on each startup if the IP changes regularly.

This can be changed in the config.yml under linkonstart

Everything should be setup now!


Whitelisting

One advantage of this bot is that you can make a role that will allow discord users with that role to add themselves to the whitelist automatically.

Firstly make a role that you want to be required in order to add to the whitelist if you don't already have one.

Then go to the online dashboard and change the required role from `No role required` to your chosen role. (Required Role on the Dashboard). Keep as `No role required` if you want all users to be able to add themselves to the whitelist.

Players should then be able to link their Discord with their Minecraft username using /whitelist link <Minecraft Name>.

And then use /whitelist me to add themselves to the whitelist.

=

Members can then use /connect to get the IP needed to connect if the `Can get display IP` is enabled. The IP they see can be also be set on the website. (Can get display IP on the Dashboard)


Troubleshooting

Port Forwarding

For the discord bot to communicate with the Minecraft server, the configured port must be port-forwarded and accessible from the internet. This by default is 9000 and can be changed.

The Plugin does not start correctly

This can happen for a couple of reasons.

One major one is that the port it is trying to listen to is being used by something else.

To fix this, simply use /discraft port <new port> or change the config.yml port field of the minecraft server and restart.

Then use set the new port on the dasboard update the bot.

This should fix it. If not then send an email to hourglassprograms@gmail.com or send a DM to BurntWindow#3449 on Discord.

ECONNREFUSED error when whitelisting

This error occurs when the plugin is unable to correctly obtain the server IP and so needs to be set manually.

Simply enter this on the dashboard and do /status to test.

If this does not fix it, send an email to support@hourglassprograms.com or a DM to BurntWindow#3499.