changed pedestrian movement logic