While studying I was doing a lot of different projects. One of them was a simple simulation of bird flock movements. This will be a series of posts about changes in this project. It will contain a lot of code reviews and development information’s.
Project is hosted on GitHub if you want to follow the code and changes.
I use Trello to manage ideas, tasks, bug fixes etc.
This app is simulating movement of bird flocks. Each object that is representing single bird is called BOID. Each of them can perform various actions which are influencing behavior and in the end vector, that is responsible for the movement in the next iteration.
More complex description of the algorithms involved in this project.
Boid is rendered as a simple pixel. There are options like
- Add new boid
- Add Random boid
- Options for different behavious
It is very simple
Each Iteration of the simulation world is divided into these actions
For each Boid we perform Do Actions function which iterates through Action list and create a Vector class that is describing current movement and position change of the Boid. After caluclation we perform position change and Rerender of world. This is just a simple explanation of engine.
I also have to think about nice and easy Gui.
I want to support couple of nice features in future releases
- Ability to modify\ behavioral algorithms
- Simple Game based on the engine
- Html 5 Canvas rendering + web service communication
- Storing state either on Redis or MsSql with NHibernate layer