Emitter disappearing when particlesFollowEmitter is false

Whenever I call emitter.setParticlesFollowEmitter(false); the Emitter no longer appears in the scene. The same emitter renders properly in its correct position if I leave that value true.

It seems like this could be a bug related to the positioning of an Emitter when it is positioned very far from the origin (0,0,0) since the library’s particle examples appear to not have this bug (I think) but the bug consistently occurs with any emitter in my game as long as it has that value set to false.

I’ve also downloaded and built the latest master branch to make sure I’m up to date, but the issue still occurs. Any ideas on what could be causing this issue? Thanks :slightly_smiling_face:

So particle monkey does exactly the same thing as the existing emitter as far as how it handles particles following the emitter. It’s possible that maybe it’s being culled since the position of the particle mesh would be (0,0,0).

Try setting the cull hint to never maybe?

2 Likes

I just gave that a try but the Emitter still doesn’t appear. I also tried changing the BillBoard mode to see if the issue had something to do with the direction the particles are facing when followEmitter is false, but still see nothing.

I was able to reproduce it. Trying to figure out the best way to fix it right now.

1 Like

Okay, I pushed a change to my master branch. See if that works for you. I was able to get it working in my example project but there was some weirdness on the jme side with how it handled culling when the emitter was the only visible object in the scene.

2 Likes

Thanks for the quick fix!

I built and tested the updated master branch, and the Emitter still disappears when left in Dynamic culling, but it does become visible and works as expected when set to CullHint.Never

1 Like

That’s pretty much what I would expect it to do. The stock jme emitter would probably do the same thing. I think I tried to do it differently at one point, but the math became too complicated and I just kept it the way it was. Glad the fix helped.

2 Likes