This API is aimed primarily at beginner plugin-makers.
- Native Minecraft Version:
- Tested Minecraft Versions:
- Source Code:
- Mackenzie (Moderocky), blce
The primary goal is to try and simplify most of the dull or complex tasks that are required in plugin creation.
I use this in production, which is pretty much a guarantee that I will keep it updated and maintained.
Almost no features rely on Minecraft version-specific methods so it ought to work on almost any version.
Note: You probably want to get this via the repository, the jar itself won't be much help.
Looking for the JavaDocs?
Looking for the Repository?
Looking for the Support Discord?
Looking for the Mask Wiki?
- Simplifying basic tasks
- Simplified one-step yaml converters
- Built-in configurable web server template system
- Configurable jSon-based web API system
- Special callback system for advanced tasks
- Easy reflection API (good for tricky NMS work)
- Item factory for faster creation/editing of items
- GUI menu creation system (BETA)
- Automatic object property expression generation (BETA)
- Automatic config-handling annotations
- Additional debug tools
- Automatic Skript addon registration (using Plugin template)
- Exposition of some extra features from Skript
- Remote socket API
- Annotations for automatic Skript effect generation (good for exposing your plugin for Skript)
- Improved debug systems
- Template data storage system
Package re-mapping (prevents conflicts if there are two plugins using this dependency).Code (Text):
I don't know how Gradle handles package mapping.
I'm sure you can work this out for yourselves.
This seems to be the most popular feature, so I've tried to provide a simple example.
Mask contains a simplified config handler that makes use of annotations.
This can be used to easily serialise/de-serialise your config.
An example config can be seen here.
To use, implement the 'Config' interface.
Remember: by default, your field-names are converted from camelCase to snake_case to provide the yaml key.
If you want to change this, you can use the @Keyed annotation to specify something else.
Code (Text):@Configurable // marks this field to be mapped
@Bounded // sets bounds for a number field
@Keyed // allows a custom yaml key to be used
@Regex // passes string input through a matcher
@Comment // allows a comment to be left
@Serialise // currently does nothing, will soon allow a custom (de)serialising method to be used
@Header // attaches to the class, specify yaml header comments
Remember: many more feature examples can be found in the repository.
Other basic examples can be found here: https://gitlab.com/Pandaemonium/Mask/-/tree/master/src/examples
I will try to remember to add more as I add more features.