Skip to content

A Minecraft Bedrock (Windows 10, iOS, Android, XBox, PS) server monitor bot with discord relay functionality

License

Notifications You must be signed in to change notification settings

stevarino/bedrock-discourse

Repository files navigation

Pocket Prattle

A Minecraft Bedrock (aka Pocket Edition) bot that provides server monitoring, Discord relay, and other server administration features.

What Pocket Prattle is not:

  • Not a minecraft mining bot
  • Not a minecraft combat bot
  • Not a minecraft bot that has any physical interaction with the minecraft world.

What Pocket Prattle is:

  • Chat relay via Discord, allowing users on consoles to use their phones for chat or afk players to participate with in-game events.
  • Event logger, allowing you to keep detailed statistics and logs of Minecraft activity (log in/out, chat messages, deaths, etc).
  • Server performance monitor, including server-side ticks per second (TPS).
  • In-game email server, allowing for asyncronous messaging such as announcements.
  • A command-line client, allowing arbitrary commands to be run from either discord or in-game with robust access-control. These require server specific commands to be configured, but possible examples include:
    • Editing the allowlist
    • Allowing teleport, creative mode, and other minecraft server commands, regardless of cheats settings.
    • Monitoring server health remotely.
    • Restarting Minecraft server.
    • Updating Minecraft server.

See the configuration file example for an minimal setup and the configuration schema for detailed documentation of all the features.

To run the bot, enter the following command after creating your config file:

nodejs index.js config.yaml

For more explanation of the different parts, read below.

Minecraft Integration

The minecraft agent is very simple, just logs in to your world. However when combined with the other features below, it can achieve things typically not possible.

Prometheus Client Web Server

When the webconfiguration is supplied, Pocket Prattle creates a web server on the specified host/port combination. This will allow the collection of all types of data, including:

  • Current tick
  • Estimated tps
  • Time and Weather
  • Counter of who has slept
  • Counter of who has died and by what (or whom)
  • Counter of who has chatted

All this data is exposed in a text format designed for Prometheus ingestion.

Prometheus is an open source time-sequenced metric database - it makes graphs. It is not required for this project as the web endpoint Pocket Prattle exposes can be directly read.

Discord Proxying and Fowarding

The bot can connect to multiple discord servers (guilds) and channels. Custom routing rules can be set up so a single Pocket Prattle instance can monitor multiple Bedrock Servers, relaying messages to corresponding discord channels.

SQLite database

Used for permanence of players, statistics, and certain messages.

ACLs and Commands

Pocket Prattle allows for complex ACLs via the groups settings. Actions and Commands can be arbitrarily ACL'd to a specific server, and/or for a specific command.

Actions are generic interactions with the bot. A sub set of actions are Commands, which are configuration-defined command-line operations.

About

A Minecraft Bedrock (Windows 10, iOS, Android, XBox, PS) server monitor bot with discord relay functionality

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published