This project is a part of the p5.js series where we explore how to create an interactive bouncing ball simulation. In this project, each ball bounces off the edges of the canvas and changes color when colliding with an edge. New balls are generated at the mouse position whenever you click, and if you hold down the mouse button, multiple balls are created continuously.
- Balls change color when they collide with the canvas edges.
- Balls can collide with each other and bounce off.
- New balls are created with random velocity at the mouse position upon clicking.
- Continuous ball generation by holding down the mouse button.
- Clone the repository:
git clone https://github.com/BigCodeNeck/p5js-Bouncing-Balls.git
- Open the index.html file in your web browser or upload it to a local p5.js server to run the project. Demo Video Watch the full tutorial on YouTube to see how this project is built step by step: https://youtu.be/NQK9cbsCXKk
Requirements p5.js library (included in the project) License This project is licensed under the MIT License - see the LICENSE file for details.
Happy coding! Make sure to subscribe to my channel for more creative coding tutorials!