Fixed functions in pathfinding logic

I found those two inconsistencies while browsing the code. Someone familiar with the PathFinder and ObstacleCheck should have a look if I interpreted those functions correctly.