This epic boids simulation implements classic flocking behaviors:
Separation: Boids avoid crowding by steering away from nearby boids.
Alignment: Boids try to match the average heading of nearby boids.
Cohesion: Boids move toward the average position of nearby boids.
Additional behaviors include obstacle avoidance, fear (repulsion from obstacles), and leadership – where a few boids become leaders that wander toward random targets and gently influence the flock.
Enjoy tweaking the controls and watching the emergent behavior!
Made with retro vibes and a passion for simulation.