-
-
Notifications
You must be signed in to change notification settings - Fork 4
Developers API
Berke Akçen edited this page Jan 22, 2022
·
27 revisions
The project isn't in the Central Repository yet, so specifying a repository is needed.
To add this project as a dependency to your project, add the following to your pom.xml:
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
<dependency>
<groupId>com.github.Despical</groupId>
<artifactId>KOTL</artifactId>
<version>2.0.0</version>
<scope>compile</scope>
</dependency>
repositories {
maven { url 'https://jitpack.io' }
}
dependencies {
compileOnly group: "com.github.Despical", name: "KOTL", version: "2.0.0";
}
This event calls when user's any statistic change.
@EventHandler
public void onStatChange(KOTLPlayerStatisticChangeEvent event) {
StatsStorage.StatisticType stat = event.getStatisticType();
int value = event.getNumber();
event.getPlayer().sendMessage("Updated statistic name: " + stat.name() + " , Updated value: " + value);
}
Enum Name | Statistic ID | Persistent | Description |
---|---|---|---|
TOURS_PLAYED | toursplayed | true | Played tours amounts |
SCORE | score | true | Total score amount |