public void update() {
        if (hasGameStarted()) {
            if (keyListener.isUp()) {
                sessionImpl.update(-1);
            } else if (keyListener.isDown()) {
                sessionImpl.update(1);
            } else {
                sessionImpl.update(0);
            }
        } else if (!hasGameStarted() && hasGameStopped()) {
            //game was started but interrupted (so hasGameStarted() is false)
            gameloop.interrupt();
            button1.setLabel("Find game!");
        }
    }