-
Notifications
You must be signed in to change notification settings - Fork 50
Getting started
koca2000 edited this page Jul 22, 2023
·
5 revisions
Add this to your maven pom:
<repositories>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>
<dependency>
<groupId>com.github.koca2000</groupId>
<artifactId>NoteBlockAPI</artifactId>
<version>1.6.2</version>
<scope>provided</scope>
</dependency>
Add this to your build.gradle:
repositories {
...
maven { url 'https://jitpack.io' }
}
dependencies {
compileOnly 'com.github.koca2000:NoteBlockAPI:1.6.2'
}
Now add this line to your plugin.yml: depend: [NoteBlockAPI]
If is NoteBlockAPI only optional dependency use: softdepend: [NoteBlockAPI]
and check if is present in onEnable function:
boolean NoteBlockAPI = true;
if (!Bukkit.getPluginManager().isPluginEnabled("NoteBlockAPI")){
getLogger().severe("*** NoteBlockAPI is not installed or not enabled. ***");
NoteBlockAPI = false;
return;
}
About types of SongPlayer and how to use them you can read here.