I have an update planned for magnets, and it seems as if I need this. It is easy to detect when it enters the radius of a particle... But not for going out of that radius.
So what I need to know, is how can I detect a particle leaving my for loop?
You check for particles that are about to leave the radius. meaning you check to see if that particle will leave the radius the next frame by using vx and vy to see the approximate next position. It's the best I could think of