This repository has been archived by the owner on Jun 19, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
Getting Started
MrSlimeDiamond edited this page Dec 6, 2021
·
1 revision
- Basic Java Knowledge
- An IDE to work in
- Add the repository
repositories {
maven {
url = "https://repo.zenoc.net/repository"
}
- Add the dependency
dependencies {
implementation 'ml.glucosedev:GlucoseLib:1.0.6-BETA'
}
There's a serverStartEvent() which is called when the server starts. You can put statements in here to do when the server starts. Consider the following example
public void serverStartEvent() {
System.out.println("Green eggs and ham");
}
glucose.inf tells the server what your plugin is called, its ID, main class, and all sorts of other jazz. Example:
main-class: com.verycool.my.amazing.plugin.Main
name: My amazing plugin
id: myamazingplugin
build your plugin, put it into the plugins
directory on your server. You should see something like this before the world loads.
[17:28:13] [Glucose/PluginLoader] [Server thread/INFO]: Loading plugins...
[17:28:13] [Glucose/PluginLoader] [Server thread/INFO]: Loading plugin: TestPlugin1-1.0-SNAPSHOT.jar
[17:28:13] [net.minecraft.server.LoggedPrintStream] [Server thread/INFO]: [STDOUT]: Green eggs and ham