How to break the loop of points entering?