server.disconnected(id);
server.disconnected(this);
    private void sendPacket(Packet packet) {        try {            if (out == null) {                out = new ObjectOutputStream(socket.getOutputStream());                out.flush();            }            out.reset(); // write each packet fresh            out.writeObject(packet);            out.flush();            bytesSent += packet.size();//            System.out.println("server(" + id + "): command #" + packet.getCommand() + " sent with " + packet.getData().length + " data");        } catch(IOException ex) {            System.err.println("server(" + id + "): error sending command.  dropping player");            System.err.println(ex);            System.err.println(ex.getMessage());            server.disconnected(id);        }    }