- Home /
performance question about particles and instantiating
ok so i have a light prefab that i can shoot out and when it gets shot out it instantiates a spark particle from the resources folder where it collides, and i put these light prefabs all over levels
my question is what is my best way to play the particle at a collision point that is best for performance
should i:
-have 1 particle in the scene and move it and play it at each collision
-have a particle as part of each prefab and just play it
-instantiate the particle when it collides (how i have it now)
i really dont know what would be the least laggy way...thanks
Answer by Owen-Reynolds · Aug 06, 2013 at 01:11 AM
Reusing a single particle is the fastest -- But: the most reliable way is to Instantiate each time. it can often be a pain to properly reset reused items.
Test running it without any particles. If there's no change in "lagginess," then just leave it and move on.
luckily my game isnt laggin yet i was just wondering in case i gotta optimize later, thank you
Your answer
Follow this Question
Related Questions
How do I make instantiated particles inherit Transform movement from their parent object? 1 Answer
Syncing particle system in Photon Unity Networking 1 Answer
How to Instantiate gameObject where a particle dies 2 Answers
Very Bad Lag from ~20 Large Particles 0 Answers
Manually and efficiently placing thousands of particles 0 Answers