@EventHandler public void onPlayerWhois(InfoComponent.PlayerWhoisEvent event) { if (event.getPlayer() instanceof Player) { Player player = (Player) event.getPlayer(); LocalPlayer localPlayer = plugin.wrapPlayer(player); if (WorldGuard.getInstance().getPlatform().getGlobalStateManager().get(localPlayer.getWorld()).useRegions) {
@EventHandler public void playerWhois(InfoComponent.PlayerWhoisEvent event) { if (event.getPlayer() instanceof Player) { if (CommandBook.inst().hasPermission(event.getSource(), "commandbook.god.check")) { event.addWhoisInformation(null, "Player " + (hasGodMode((Player) event.getPlayer()) ? "has" : "does not have") + " god mode"); } } }
@EventHandler public void playerWhois(InfoComponent.PlayerWhoisEvent event) { if (CommandBook.inst().hasPermission(event.getSource(), "commandbook.bans.isbanned")) { event.addWhoisInformation(null, "Player " + (getBanDatabase().isBanned(event.getPlayer().getUniqueId()) ? "is" : "is not") + " banned."); } }