API instance that PerPlayerKit registers at startup. The surface area is intentionally small: retrieve a list of configured public kits, then apply one to any online player with a single method call.
Adding the Dependency
PerPlayerKit is not published to a public Maven repository, so you need to add the plugin jar to your project manually.- Place
PerPlayerKit-1.1.jarinside alib/folder at the root of your project. - Declare it as a
system-scoped dependency in yourpom.xml:
pom.xml
Add
PerPlayerKit to the depend (or softdepend) list in your plugin.yml so Paper loads PerPlayerKit before your plugin. Without this, API.getInstance() may be called before PerPlayerKit has initialised, returning an uninitialised instance.Obtaining the API Instance
Importdev.noah.perplayerkit.API and call the static getInstance() method. You can call this anywhere after your plugin has loaded — typically inside an event handler or command executor, after PerPlayerKit is guaranteed to be enabled:
Available Methods
The following methods make up the current public API surface:| Method | Return Type | Description |
|---|---|---|
API.getInstance() | API | Returns the singleton API instance, creating it if it does not yet exist. |
api.getPublicKits() | List<PublicKit> | Returns a copy of the list of all public kits configured in PerPlayerKit. |
api.loadPublicKit(Player, PublicKit) | void | Loads the given public kit for the specified online player, silently (no chat message). |
PublicKit object exposes an id (String), a name (String), and an icon (org.bukkit.Material) that you can use to identify or display kits in your own UI.
For a complete, runnable integration example, see the Usage page.