Fixed getTimeToBoundaryCollision()