@EventHandler
public void onJoin(AsyncPlayerPreLoginEvent evt) {
KCPlayer player = KCPlayer.getWrapper(evt.getUniqueId());
if (player.isBanned())
evt.disallow(AsyncPlayerPreLoginEvent.Result.KICK_BANNED,
ChatColor.RED + "You are banned from Kineticraft!\n"
+ ChatColor.RED + "Reason: " + ChatColor.YELLOW + player.getPunishments().last().getType().getDisplay() + "\n"
+ ChatColor.RED + "Expiration: " + ChatColor.YELLOW + Utils.formatTimeFull(player.getPunishExpiry()) + "\n"
+ ChatColor.RED + "Appeal on discord: http://kineticraft.net");
}
Punishments.java 文件源码
java
阅读 24
收藏 0
点赞 0
评论 0
项目:Kineticraft
作者:
评论列表
文章目录