Explore the RxJs API by managing moving particle systems. The systems should:
- Use self-aware AI, not a global AI
- Move in organic, natural arcs, with no sudden pivots or swerves
- Support large swarms of particles
- Be able to evade obstacles
- Exhibit flocking behavior
The trickiest portion of this iteration (and perhaps the whole project) was animating the curved paths:
The current design uses circular paths that allow smooth changes in both direction and rotation.
This method can handle quite a few particles.
The next goal was to explore a grid-based vision system. Each particle owns a vision grid, which is compared against the global grid to detect collisions. Here's a small scale system, with the vision grid visualized:
Here's a large scale system.
The last goal was to play around with flocking behaviors: cohesion, separation, and alignment. Here's each of the three, with the vision grid visualized:
The exploration is now complete: arc-based movement, independent AIs, grid-based vision, following patterns of cohesion, separation, alignment, with hazards, on a large scale: