private void checkCoords(PlayerMoveEvent event, Player player, boolean isTeleport) { plugin.debug("FlyingListener Check Coords : " + isTeleport); if (!player.getAllowFlight()) return; SimpleIsland isle = plugin.getPlayerIsland(player); final SimpleIsland isleh = plugin.getHelpingIsland(player); if (isle == null && isleh != null && plugin.getOurConfig().isHelperAllowed("home")) isle = isleh; if (isle != null) { if (plugin.isInsideIslandCuboid(event.getFrom(), isle) && !plugin.isInsideIslandCuboid(event.getTo(), isle)) { if (isTeleport) { plugin.showMessage(player, ChatColor.AQUA + plugin.getLoc("info-flying-dis-tele")); player.setAllowFlight(false); } else { plugin.showMessage(player, ChatColor.AQUA + plugin.getLoc("info-flying-dis")); event.setCancelled(true); } } } }