I want to have like 100 leafs on the screen at the same time without making it lag/lose FPS. Not just that, I want to controll the dt of every leaf (Make every leaf go slower/faster). I could make a factory but I don’t want to ping a speed message to everty leaf everytime I change the dt.
Do you want to change the speed of each leaf dynamically as it falls, or just have some leaves constantly falling faster than other leaves?
If changing the speed dynamically, do you want to do it differently for each individual leaf, or do you want all the leaves to speed up and slow down in the same way at the same time?
Create the leaves using a factory and put them in a list. In the same script you can move all of them and control their speed. Having a script on each leaf and pushing a speed to them is a typical OOP design, but it’s not very efficient.