Pathfinding is not optimal but works