Advertisement
Guest User

Untitled

a guest
Aug 3rd, 2014
36
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. public class JoinListener implements Listener {
  2.  
  3. @EventHandler
  4. public void onPreLogin(PlayerLoginEvent event) {
  5. String banReason = MySQL.getBannedReason(event.getPlayer().getUniqueId());
  6. if (banReason != null) {
  7. event.setResult(PlayerLoginEvent.Result.KICK_OTHER);
  8. event.setKickMessage(banReason);
  9. }
  10. }
  11. }
Advertisement
Advertisement
Advertisement
RAW Paste Data Copied
Advertisement