public void startPolling() {
        pollingActive = true;

        Runnable pollingTask = () -> {
            while(pollingActive) {
                //wait for a bit
                try {
                    Thread.sleep(2000);
                } catch (InterruptedException e) {
                    e.printStackTrace();
                }

                //ask server if it knows about any new moves
                try {
                    Move newMove = myRemoteObject.getNewMove(myInformation.getPlayerId(), myInformation.getGameId(), myInformation.getServerId());
                    if (newMove != null) {
                        char a = 'a';
                        int startingColumn = newMove.getStartingColumn() - a;
                        int startingRow = 8 - newMove.getStartingRow();
                        int targetColumn = newMove.getTargetColumn() - a;
                        int targetRow = 8 - newMove.getTargetRow();
                        networkMoveListener.onNewMove(startingColumn, startingRow, targetColumn, targetRow);
                    }
                } catch (RemoteException e) {

                    System.out.println("server disconnected");
                    e.printStackTrace();
                    try {
                        System.out.println("trying to reconnect");
                        context = new InitialContext();
                        myRemoteObject = findWorkingServer();
                        System.out.println("reconnect successful");
                    } catch (NamingException ex) {
                        ex.printStackTrace();
                    }
                }


            }
        };

        Thread t = new Thread(pollingTask);
        t.start();
    }