Implemented a dynamic flocking system in Unity. The simulation replicates natural group movement by programming boids to follow three key rules: separation, alignment, and cohesion. Each boid dynamically adjusts its trajectory based on nearby neighbors, creating smooth and realistic flocking behavior. This project demonstrates the use of vector mathematics and real-time interaction for emergent gameplay and visual effects.
Key features include:
- Flocking Behavior: Inspired by industry-standard techniques, individual boid agents demonstrate natural steering, alignment, and avoidance behaviors. The CPU-based docking algorithm further refines this by guiding boids to accurately dock at designated positions.
- Custom Bezier Path System: Waypoints with adjustable tangent offsets are used to generate smooth, pre-baked Bezier curves. This approach provides visually appealing and fluid motion paths that enhance the overall simulation quality.
- Editor Tools and Utilities: Custom editor scripts facilitate intuitive in-scene path editing, allowing for easy adjustments to waypoint positions and tangents. Additional utilities such as probabilistic functions and dynamic skybox shader management further enrich the project.
This system showcases my ability to blend algorithmic complexity with creative design, resulting in a visually engaging and technically sound simulation environment in Unity.
Source Code on Github
https://github.com/payam-ranjbar/Flocking-Boids-System-Unity
Leave a Reply