This is a BOID calculation. May be slow above 70 points. NOTE: how_many_points needs to have the flag pressed again to activate correctly. Press to change settings. 100% pen! (except for the variables) Adjust - the angle that adjusts for when current is out of aligment with other boid members. Threshold - a threshold for when current should switch from going torwads to moving away Speed - the speed as which current moves. detection radius: the radius of the circle for detection of points. Direction-pointer: show direction pointers. Will try to add obstacle avoidance, will be hard.
all me and a few math forums to help me get the math right. No imported code!