Click around. Collect magic wands.
A random search algorithm that adjusts the space it searches in is very fast at finding paths that are good enough. To increase the chance of finding a path that looks like the shortest path, set the improve path? variable to 1. To almost 'guarantee' a path that looks like the shortest path, increase the max tries variable above 500.