Uploaded April 2019 | Updated September 2026, 17 minutes ago
This engine allows the user to input hundreds of objects, and in using very simple code, create what appears to be a flock of birds or a shoal of fish. This video demonstrates 200 "creatures", running at a fast smooth frame rate.
This is my second attempt at "emergent behaviour" - i.e. AI that is coded with just a small number of commands, but that in a group appear to be controlled by some larger intelligence. The approach I've used in this video is quite a bit more advanced than in my last Swarm video - and I think the code is a lot better and can expand to other behaviours / creature types a lot easier. It still requires some fine tuning so I will wait until then to release the code on GitHub.
My aim is to have multiple types of AI that you can spawn and see how they interact with each other - my next video will demonstrate attacking creatures (e.g. sharks on fish).
Please let me know how if you have any suggestions on things to add!
Acknowledgements:
This was made using the Chili Framework: http://wiki.planetchili.net/index.php... - thanks Chili!
The ideas of using simple states to create emergent behaviour came about while reading Mat Buckland's book "Programming Game AI by Example". This code uses ideas similar to the Seek / Cohesion, Evade / Separation, and Align AI states.
This engine allows the user to input hundreds of objects, and in using very simple code, create what appears to be a flock of birds or a shoal of fish. This video demonstrates 200 "creatures", running at a fast smooth frame rate.
This is my second attempt at "emergent behaviour" - i.e. AI that is coded with just a small number of commands, but that in a group appear to be controlled by some larger intelligence. The approach I've used in this video is quite a bit more advanced than in my last Swarm video - and I think the code is a lot better and can expand to other behaviours / creature types a lot easier. It still requires some fine tuning so I will wait until then to release the code on GitHub.
My aim is to have multiple types of AI that you can spawn and see how they interact with each other - my next video will demonstrate attacking creatures (e.g. sharks on fish).
Please let me know how if you have any suggestions on things to add!
Acknowledgements:
This was made using the Chili Framework: http://wiki.planetchili.net/index.php... - thanks Chili!
The ideas of using simple states to create emergent behaviour came about while reading Mat Buckland's book "Programming Game AI by Example". This code uses ideas similar to the Seek / Cohesion, Evade / Separation, and Align AI states.








![Transparent Windows feat. Bevy [Rust]
After only spending a few hours this weekend, I was able to code up a simple image overlay with a couple of fun features. Code was surprising easy to implement for the effect I was going for.
Hopefully this will lead to some future videos as I journey through learning Rust. Transparent Windows feat. Bevy [Rust]](https://i.ytimg.com/vi/gymEcIAi_J8/mqdefault.jpg)

