(AsyncPlayerChatEvent e)
| 85 | } |
| 86 | |
| 87 | @EventHandler(priority = EventPriority.LOWEST) |
| 88 | public void onChat(AsyncPlayerChatEvent e) { |
| 89 | Prompt p = prompts.remove(e.getPlayer()); |
| 90 | if (p == null) { |
| 91 | return; |
| 92 | } |
| 93 | e.setCancelled(true); |
| 94 | if (e.getMessage().equalsIgnoreCase(RedLib.msg("cancelText"))) { |
| 95 | p.cancel(CancelReason.PLAYER_CANCELLED); |
| 96 | return; |
| 97 | } |
| 98 | p.respond(e.getMessage()); |
| 99 | } |
| 100 | |
| 101 | @EventHandler |
| 102 | public void onLeave(PlayerQuitEvent e) { |