Skip to main content

Creating your Plugin

A Zora Plugin is in essence just a Minecraft plugin with a few extra features.

The Plugin Class

The plugin class is extremely similar to a Paper plugin -- indeed, it is a subclass of JavaPlugin. However, it also contains a few additional features which improve the quality of life for developers.

It should be noted that in Zora, any configuration file (which uses the JSON configuration format) is automatically populated in the /zora/<pluginId> directory of the root server (i.e. it is not in the plugins directory). This is designed to enable custom content to be quickly distinguished from the rest of the server's configuration.

import ltd.redeye.zora.plugin.ZoraPlugin;
import ltd.redeye.zora.plugin.annotation.PluginMeta;

@PluginMeta(id = "myplugin")
public class MyPlugin extends ZoraPlugin {
@Override public void init() {
// Service registration etc.
}

@Override public void enable() {
// Called when the plugin is enabled
}

@Override public void disable() {
// Called when the plugin is disabled
}
}

Your plugin doesn't require anything else. By default, Zora will not do anything with your plugin. Features of Zora are made available when you add them via the init method.