move: Fix bug with random movement to go around the barriers