ClopLib (Claim Operations Library) is a Minecraft server library for handling events that take place in varying positions within game worlds, to allow developers to contextually cancel or modify the outcome of operations such as block placement, block breaking, entity spawning, based on whether the type of operation was performed within a claimed region.
Currently, ClopLib targets bukkit
servers running Spigot/Paper 1.17.1+. ClopLib requires Java 17.
ClopLib is available on Maven. You can browse the Javadocs here.
Using Maven/something else? There's instructions on how to include ClopLib on the repo browser.
/plugins
folder; ClopLib is shaded & relocated in the final jar for each plugin.Documentation on using ClopLib in your projects is a WIP! At it's core, though, HuskClaims exposes a:
Handler
interface, which you should implement in your plugin OperationUser
interface, which you should implement via your object representing online playersOperationPosition/World/Chunk
interfaces, which you should implement via your object(s) representing game world positions OperationListener
interface, and platform-specific interfaces such as BukkitOperationListener
, the latter of which you should extend to register ClopLib's handlers and supply your implementing OperationUser/Position/World/Chunk
objects. A good place to start would be looking at how HuskClaims' code implements ClopLib in its common module, and then implements the platform operation handler on bukkit.
To build ClopLib, run clean build
in the root directory. The output JARs will be in target/
.
ClopLib is licensed under Apache-2.0. See LICENSE for more information.