Added a version of the wall-finding code