PlotRand

PlotRand

Pick your plot's border style from a GUI - one permission per style.

54 downloads 0 followers

Discord Release Downloads License

Built with Java 21 Available for Paper

Chat with us on Discord Available on Codeberg

PlotRand

/rand opens a GUI where a plot owner picks a border style for their own PlotSquared plot. Every style is gated behind its own permission (plotrand.style.<id>), so a rank/donor system can unlock more styles per group without touching the plugin.

Not yet tested on a live server - see Known limitations below.

Requirements

  • Paper 1.21.x
  • PlotSquared 7.x (hard dependency, plugin refuses to enable without it)

Commands

Command Description
/rand Opens the border GUI for the plot you're standing on (must be yours)
/rand set <style> Sets a style directly, without the GUI
/rand remove Removes the border and restores the original blocks
/rand info Shows the currently applied style
/rand admin reload Reloads config.yml
/rand admin set <style> Force-sets a border on the plot the admin is standing on, bypassing ownership and cooldown

In the GUI, a left click applies a style and a right click previews it: the ring appears along the plot edge for preview-seconds (10 by default), visible only to you. Nothing in the world changes, so a preview costs no cooldown, and locked styles can be previewed as well.

Permissions

  • plotrand.use (default: true) - allows opening /rand at all
  • plotrand.admin (default: op) - admin subcommands
  • plotrand.style.<id> - one per style in config.yml, see plugin.yml for the defaults

Configuration

All styles, the GUI layout, the cooldown, and the border height offset live in config.yml. Add a new style by copying a block under styles:, then declare its permission in plugin.yml too so permission plugins can list it.

Styles are validated when the config loads. A style is skipped, with a reason in the console, when its material cannot be placed as a block, has no item form to show in the GUI, sits in a slot the GUI is too small to show, or wants a slot another style already uses - instead of failing later mid-build.

How the border is placed

The ring follows the outline of the plot's claimed area. For a merged plot that is the outline of the union of its regions, not their bounding box: an L-shaped merge has a bounding box that reaches into a plot the owner does not own, and building there would modify someone else's plot. Seams where two merged sub-plots meet are left out, so a merged plot reads as one shape.

Blocks are placed without physics updates, so a ring of several hundred blocks does not set off falling sand, redstone or water flow along the plot edge.

Known limitations

  • Border height: the ring is placed at the Y level the player is standing on (plus border-height-offset), not at a PlotSquared-defined floor height. Fine for flat plot worlds; on varied terrain the owner has to stand where they want the ring.
  • Admin set only targets the plot the admin is physically standing on - there is no lookup-by-plot-ID yet.
  • Restoring the original blocks (/rand remove, or switching styles) replays a snapshot taken when the border was first applied. Blocks placed by other means on those exact coordinates afterwards are overwritten. If a stored block type no longer exists after a Minecraft update, the restore is refused as a whole and the stored data is kept, rather than stranding the border with its originals already deleted.
  • applyStyle runs on the main thread and will force-load unloaded chunks along the plot's edge. Only the outline is walked (not the plot's area), so the cost scales with edge length, but a very large plot may still hitch briefly. The state file is written asynchronously.

Building

mvn clean package

Needs network access to repo.papermc.io (Paper), Maven Central (PlotSquared) and maven.enginehub.org (WorldEdit, SquirrelID). The resulting jar is in target/; Paper, PlotSquared and WorldEdit are provided and not shaded in.

WorldEdit is pinned to 7.3.19: Plot#getRegions() returns WorldEdit types, and from 7.4.0 on WorldEdit ships Java 25 class files that a Java 21 build cannot read. The code deliberately uses BlockVector3.getX() rather than the newer x(), since the latter only exists from WorldEdit 7.3.0 and the runtime version is whatever the server provides.

No gallery available for this project.

Version Minecraft Loader Download

1.0.0

1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11, 26.1, 26.1.1, 26.1.2, 26.2, 26.3
bukkit, paper, spigot
Download

PlotRand 0.1.1

0.1.1

1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11, 26.1, 26.1.1, 26.1.2, 26.2
bukkit, paper, spigot
Download

PlotRand 0.1.0

0.1.0

1.21, 1.21.1, 1.21.2, 1.21.3, 1.21.4, 1.21.5, 1.21.6, 1.21.7, 1.21.8, 1.21.9, 1.21.10, 1.21.11, 26.1, 26.1.1, 26.1.2, 26.2
paper
Download