The best way to create a plugin
- Kotlin (License)
- JetBrains Annotations (License)
- commons-io (License)
- Google Gson (License)
- Zip4J (License)
This can be found here (it's a Dokka Resource), everything is documented through the Kotlin Docs (Similar to JavaDocs but for Kotlin :p )
Ok, so we have multiple types of initializers for different software, Spigot, Bungee, Velocity and Standalone.
The Standalone system works by loading all jars under the modules/ folder into the current classpath.
The other kinds of software will use their embedded plugin system to avoid difficult tasks, like sorting modules to be loaded.
In the Standalone system you will naturally shade SimpleCoreAPI and use the xyz.theprogramsrc.simplecoreapi.standalone.StandaloneLoader
as your main class.
Later you will mark your main class with the @EntryPoint
annotation. Then SimpleCoreAPI will load all modules, then execute the @EntryPoint
class.
Depending on the software you're using you'll need to mark SimpleCoreAPI and the modules you need as dependency
(NOT soft-dependency
) so the system will load all
modules and files you need before your plugin is loaded.