public void moveCharacters() {
        for (Character character : characters.values()) {
            ArrayList<Room> neighboursList = character.getLocation().getNeighbours();
            boolean found = false;
            // if character's hostile, stay if player's in the same room. If not, sense if player's in a nearby room and go there if found. If not, go randomly as usual.
            if (character.getHostile()) {
                if (character.getLocation() == player.getLocation()) {
                    return;
                }
                for (Room neighbour : neighboursList) {
                    if (player.getLocation() == neighbour) {
                        Room nextRoom = neighbour;
                        character.addLocationHistory(nextRoom);
                        found = true;
                    }
                }
            }
            // randomly go to a nearby room.
            if (!found && character.getMoveable() && random.nextInt(2) == 1) {
                Room nextRoom = neighboursList.get(random.nextInt(neighboursList.size()));
                character.addLocationHistory(nextRoom);
            }
        }
    }