4.1: Particle System Simulation – The Nature of Code
29907 , 4.98 , #Particle #System #Simulation #Nature #Code
Welcome to Chapter 4 of The Nature of Code: Particle Systems! I begin by coding a simple particle system in p5.js. I convert the Mover class into a Particle class, add a lifetime property and organize a collection of particles into an array.
🕹️ p5.js Web Editor Sketch:
🎥 Previous:
🎥 Next:
🎥 All videos:
Links discussed in this video:
🔗 Particle Systems – A Technique for Modeling a Class of Fuzzy Objects:
Other videos mentioned in this video:
🎥 Simple Particle System – Coding Challenge #78:
🎥 Simulating Forces – Nature of Code 2.1:
🎥 Arrays of Objects – p5.js Tutorial 7.3:
🎥 Fireworks! – Coding Challenge #27:
🎥 Array Functions: filter():
🎥 Removing Objects from Arrays – p5.js Tutorial 7.5:
Timestamps:
0:00 Welcome to chapter 4!
0:24 Explain! What is a particle system?
1:24 Explain! What do we have to code?
2:01 Code! Let’s make a particle class!
2:46 Code! Adding a lifetime property.
3:41 Code! Many particles!
5:16 Code! Emitting particles.
5:51 Code! Removing finished particles from the array.
7:59 Code! Let’s make a few tweaks to this system?
8:55 What’s next?
🚂 Website:
👾 Share Your Creation!
🚩 Suggest Topics:
💡 GitHub:
💬 Discord:
💖 Membership:
🛒 Store:
📚 Books:
🖋️ Twitter:
📸 Instagram:
🎥 Coding Challenges:
🎥 Intro to Programming:
🔗 p5.js:
🔗 p5.js Web Editor:
🔗 Processing:
📄 Code of Conduct:
Nguồn: https://game5s.net/