path collision detection