Skip to content

Implementation of boids after seeing the The Coding Train video. Utilises the rules described by Craig Reynolds

License

Notifications You must be signed in to change notification settings

loguek/flocking-pixi

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple project arising from Covid-19 boredom...

Flocking simulation using Pixi JS

Implementation of Craig Reynold's flocking approach. Inspired by The Coding Train on youtube ... taking a break from looking at videos on woodworking :)

Screen Grab

  • Boids are can be given a limited view
    • View can be restricted by FOV and distance (via code!)
    • View cone starts from the front of boid as opposed to the centre of it
    • View cones can be enabled/disabled (via code!)
  • View adjusts to window size (including debounce implementation)
  • Cursor avoidance
  • Colour of boid is based on the angle of the boids velocity
  • Ability to set the percentage of each force applied

Todo

  • Optimise performance
  • Enable manipulation of rules
  • Add cursor avoidance
  • Add screen edge avoidance

To run

npm i && npm start

Live Demo

coderadical-flocking

References

Craig Reynold

Coding Challenge Flocking Video

Coding Challenge Youtube channel

About

Implementation of boids after seeing the The Coding Train video. Utilises the rules described by Craig Reynolds

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published