I'm not doing anything exceptional here, I just have a particle emitter set up to leave a trail of particles with a collider on them. That all works fine except that the trail is too spuratic when left to the standard emitter.
I set the emitter to have a maximum number of particles 0 so that it would not automatically emit particles, then tell it to emit a particle every fixed update. This gives me great control over the flow of particles from my system, but now the particles don't collide.
I've tested a couple different ways and determined that from the same emitter any particle automatically emitted generates a collision message like it should, but any particle that I manually produce with the Emit() function(in any of it's forms) does not. I have also found that both ways of emitting particles still make the particles bounce on collision like they should.
Has anyone else run into this kind of problem or am I out in left field? Alternative solutions to keeping track of a trail would be interesting as well.
I have exactly the same problem - particles created by assigning to
– femi.particlesproperty don't interact with collider in the same way built-in particles do. They ARE affected by particle collider's properties but don't change their direction (e.g. if bounce factor is set to 10 they will accelerate through the collider). Have you been able to solve this?Update: I have rewritten the emission code using
– femiparticleEmitter.Emit(...)calls instead of writing to.particlesand it didn't make any difference (but the code looks cleaner).This is a pretty weird problem- are you animating the particles manually, or are you using a particle animator component? I have a sneaking suspicion that world colliders work by telling the particle animator what to do.
– syclamothI use particle animator, yes they must be working together somehow. I'm gonna try to change the approach from manual emission to overriding parameters of automatically emitted particles...
– femiUpdate: my problem seems to have been unrelated to the original question. I use custom billboarding shaders for particles which assume particles of size 0 (the shader then makes sure the particle is properly resized). It's those particles that go through the colliders. Setting the particle size to
– femi1e-9solves the problem for large portion of them,1e-4makes most interact with the colliders.