Code Monkey home page Code Monkey logo

mchprs's Introduction

Minecraft High-Performance Redstone Server

Build Status License: MIT Discord Banner 2

A Minecraft 1.18.2 creative server built for redstone. Each 256x256 plot runs on a separate thread, allowing for less lag, more concurrency, and many awesome extra features!

MCHPRS is very different from traditional servers. Because this server is tailored to the use of computation redstone, many things that are a part of Vanilla Minecraft servers don't exist here. That being said, MCHPRS comes with many of its own unique features.

MCHPRS has made it possible to run programs such as Graph Rendering, Conway's Game of Life, and Mandelbrot Rendering on CPUs in Minecraft. To accomplish these speeds, we created Redpiler, the "Redstone Compiler".

Table of Contents

Building

If the Rust compiler is not already installed, you can find out how on their official website.

git clone https://github.com/MCHPR/MCHPRS.git
cd MCHPRS
rustup override set nightly
cargo build --release

Once complete, the optimized executable will be located at ./target/release/mchprs or ./target/release/mchprs.exe depending on your operating system.

Configuration

MCHPRS will generate a Config.toml file in the current working directory when starting the server if it does not exist.

LuckPerms

MCHPRS has basic support for LuckPerms with MySQL or MariaDB remote database storage. This implementation has no commands or interface and would have to be manged through LuckPerms running on a proxy (/lpb) or other server (/lp)

To use LuckPerms, append this to your Config.toml:

[luckperms]
# Define the address for the database.
host = "localhost"
# The name of the database the LuckPerms data is in.
db_name = "minecraft"
# Credentials for the database.
username = "minecraft"
password = "minecraft"
# The name of the server, used for server specific permissions.
# See: https://luckperms.net/wiki/Context
server_context = "global"

Usage

General Commands

Command Alias Description
/rtps [rtps] None Set the redstone ticks per second in the plot to [rtps]. (There are two game ticks in a redstone tick)
/radvance [ticks] /radv Advances the plot by [ticks] redstone ticks.
/teleport [player] /tp Teleports you to [player].
/teleport [x] [y] [z] /tp Teleports you to [x] [y] [z]. Supports relative coordinates. Floats can be expressed as described here.
/speed [speed] None Sets your flyspeed.
/gamemode [mode] /gmc, /gmsp Sets your gamemode.
/container [type] [power] None Gives you a container (e.g. barrel) which outputs a specified amount of power when used with a comparator.
/redpiler compile /rp c Manually starts redpiler compilation. Available flags: --io-only --optimize --export (or in short: -I -O -E)
/redpiler reset /rp r Stops redpiler.
/toggleautorp None Toggles automatic redpiler compilation.
/stop None Stops the server.

Plot Ownership

The plot ownership system in MCHPRS is very incomplete. These are the commands that are currently implemented:

Command Alias Description
/plot info /p i Gets the owner of the plot you are in.
/plot claim /p c Claims the plot you are in if it is not already claimed.
/plot auto /p a Automatically finds an unclaimed plot and claims.
/plot middle None Teleports you to the center of the plot you are in.
/plot visit [player] /p v Teleports you to a player's plot.
/plot tp [x] [z] None Teleports you to the plot at [x] [y]. Supports relative coordinates.
/plot lock None Locks the player into the plot so moving outside of the plot bounds does not transfer you to other plots.
/plot unlock None Reverses the locking done by /plot lock.

Worldedit

MCHPRS provides its own implementation of WorldEdit. Visit their documentation for more information. These are the commands that are currently implemented:

Command Alias Description
/up /u Go upwards some distance
/ascend /asc Go up a floor
/descend /desc Go down a floor
//pos1 //1 Set position 1
//pos2 //2 Set position 2
//hpos1 //h1 Set position 1 to targeted block
//hpos2 //h2 Set position 2 to targeted block
//sel None Clears your worldedit first and second positions.
//set None Sets all the blocks in the region
//replace None Replace all blocks in a selection with another
//copy //c Copy the selection to the clipboard
//cut //x Cut the selection to the clipboard
//paste //v Paste the clipboard's contents
//undo None Undoes the last action (from history)
//redo None Redoes the last action (from history)
//rstack //rs Stack with more options, Refer to RedstoneTools
//stack //s Repeat the contents of the selection
//move None Move the contents of the selection
//count None Counts the number of blocks matching a mask
//load None Loads a schematic from the ./schems/ folder. Make sure the schematic in the Sponge format if there are any issues.
//save None Save a schematic to the ./schems/ folder.
//expand //e Expand the selection area
//contract None Contract the selection area
//shift None Shift the selection area
//flip //f Flip the contents of the clipboard across the origin
//rotate //r Rotate the contents of the clipboard
//update None Updates all blocks in the selection
//help None Displays help for WorldEdit commands

Acknowledgments

  • @AL1L for his contributions to worldedit and other various features.
  • @DavidGarland for a faster and overall better implementation of get_entry in the in-memory storage. This simple function runs 30% of the runtime for redstone.

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

License

MIT

mchprs's People

Contributors

stackdoubleflow avatar al1l avatar olek47 avatar tyler569 avatar nickster258 avatar ewanfox avatar logonoff avatar skurvandrer avatar gokborg avatar shouttrickword avatar gabriel-doriath-dohler avatar garentyler avatar mortie avatar themode avatar

Watchers

James Cloos 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.