public void setDirection(char nsew) {
        if (nsew == 'N' || nsew == 'S' || nsew == 'E' || nsew == 'W')
            direction = nsew;
        else
            log.d("bad direction given to agent.");
    }