pathfinding code / touch to move; scrolling is a little awkward