👨‍💻
Utils Library
  • Welcome!
  • Getting Started
  • Examples
  • Docs
    • ⌨️Commands
    • ⚙️Configuration
    • ☎️Events
    • 🛠️Items
    • 🖥️Menus
    • 📖PlaceholderAPI
    • 📦Resources
    • 🎯Schedulers
    • 📅Sidebar/Scoreboard
Powered by GitBook
On this page

Was this helpful?

Getting Started

PreviousWelcome!NextExamples

Last updated 1 year ago

Was this helpful?

Installation

View here:

After you add the repository to your Gradle/Maven project, you have to do the following:

  1. With a JavaPlugin instance

package dev.manere.example;

import dev.manere.utils.library.Utils;

public final class ExamplePlugin extends JavaPlugin {
    @Override
    public void onEnable() {
        Utils.init(this);
        
        /* You can now use the library below this Utils initialization */
        /* Let's register a random listener that doesn't of course exist */
        Registrar.events(new WhateverListenerYouHave());
    }
}
  1. With a PluginWrapper instance from dev.manere.utils.library.PluginWrapper

package dev.manere.example;

import dev.manere.utils.library.wrapper.PluginWrapper;

public class ExamplePlugin extends PluginWrapper {
    @Override
    protected void start() {
        // Do anything you want to do with the library.
        // Obviously the PluginWrapper automatically sets up your plugin
    }
}
JitPack | Publish JVM and Android librariesjitpack
Logo