Move point generation in front of main loop