modified shortest paths to templates nad added simple points class (needs to be tested)