MVdWPlaceholderAPI
madtomic opened this issue ยท 2 comments
if (getServer().getPluginManager().isPluginEnabled("MVdWPlaceholderAPI")) {
PlaceholderAPI.registerPlaceholder(this, "combat_level", replaceEvent -> {
if (!replaceEvent.isOnline()) {
return "Player not online";
}
Player player = replaceEvent.getPlayer();
OptionalInt combatLevel = getLevel(player);
if (combatLevel.isPresent()) {
return Integer.toString(combatLevel.getAsInt());
}
return "Level not loaded";
});
}
I just notice this. Should I be using this instead of the paperholderapi?
When using combat_level, I only get Level not loaded message for the variable.
I am using version 2.1.1
I think this is still not fix when I revisit this old bug.