Just wanted to show you guys a simple AI for some fish. It’s really amazing what simple vector math and knowing the rules for flocking behavior can do.
The rules for flocking:
- Move towards the average position of the group.
- Align with the average heading of the group.
- Avoid those around you.
This works for birds, people, animals, pretty any sort of crowd.