Skip to content

lucascompython/particles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Particle Attraction/Repulsion

This is a satisfying "simulation" of particles that attract and repel to the mouse. It's not really a simulation, but it looks cool.

Keybindings:

  • R: reset the particles
  • SPACE/M1 Click: toggle the mouse attraction/repulsion
  • B: toggle the screen border collision
  • Arrow Keys (Up/Down/Left/Right): Add/Remove 1/1/100/100 particles
  • J/K: decrease/increase the multipler
  • +/-: increase/decrease ball size
  • ESC: quit

More options with ./particles --help

Demo

demo.mp4

Compilation

Install raylib on your system, then adjust the build.rs file to point to the raylib library.
Then, just run cargo build --release to compile.
I will maybe add Android and Web support in the future.

TODO

  • Add Android support
  • Add Web support
  • Add a GUI

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published