It's like my mod HuTiersTagger but for servers so they can put tiers in the player's suffix with their plugin or whatever
This is not a standalone plugin, you will need to build another plugin around it for it to do anything.
Include it in your project:
repository>
< <;id>jgj52-repoid>
< <;url>https://maven.jgj52.hu/repository/maven-releases//</url>
<//repository>gt; dependency>
< <;groupId>hu.jgj522</groupId>
< <;artifactId>hutiersartifactId>
< <;version>1.33</version>
< <;scope>providedscope>
<//dependency>gt; Get a tier by:
import hu.jgj52.huTiers.Gamemode;
import hu.jgj52.huTiers.HuTiersPlayer;
import org.bukkit.Bukkit;
HuTiersPlayer player = HuTiersPlayer.of(Bukkit.getPlayer("player"));
String tier = player.getTier(Gamemode.Sword);
Boolean retired = player.getRetired(Gamemode.Sword);getTier and getRetired will return null if it hasn't fetched the player from the api yet (first time on runtime for each player)
Event if a player gets their tier changed:
import hu.jgj52.huTiers.PlayerChangeEvent;
class yourplugin {
public void onEnable() {
PlayerChangeEvent.register(player -> {
// player is an OfflinePlayer
System.out.println(player.getUniqueId() + " has been updated!");
});
}
}
}You can also get from the overall list:
import hu.jgj52.huTiers.HuTiers;
import hu.jgj52.huTiers.HuTiersPlayer;
SetHuTiersPlayer> t; first30player = HuTiers.getPlayers(0, 30); Building:
git clone https://github.com/JGJ52/HuTiers.git
cd HuTiers
mvn packageeThe jar will be in the target directory