I’m trying to simply display a conditional particle (a particular particle based on the material struck by the particle, in my case, a bullet), at the location of where the particle meets a collider. I’ve been able to capture the array (ParticleSystem.Particle[ ]), but I don’t need all of the current particles - I just need access to the one doing the collision.
I’m thinking that if I can get the location of that particle, that’s all I need in order to be able to generate a new particle at that location. I don’t want to mess with the sub emitter system for the bullet since it will vary from material to material. So far I’ve found nothing anywhere after about 5 hours of research.
To get this straight: We are not talking about a GameObject hitting something else and spawning a ParticleSystem at the point of collision but rather an individual particle of a particle system hitting something and spawning additional particles there?
From what I read in your question you are trying to make something like a bullet hit effect. This is classically done by having a gameobject for that bullet (or not even having a bullet but just doing a raycast) and then spawning a new particle system (best practice → from a pool). This would also make it way easier to have the particle system react to what has been hit.
That’s right, I currently have it set up to have a GameObject react to a particle collision and not another object. I was considering switching from a particle-based projectile system to an object based system, but wanted to see if I could get the particle route to work since I already had a decent system in place (minus the effects I was looking for).
So, I guess I’ll have to go the object route. Weird that an event like OnParticleCollision doesn’t give us easy access to the actual particle that triggered the event, imo.
Now I’ll have to research this whole pooling thing…