Update PathFinder.js

An little bit different than loop back detection but is much much faster and makes less paths of already traveled points.