change line intersection code