WARNING : This site is outdated and the PopcornFX team will no longer answer your questions here.
For all support questions please go to our Discord server
0 like 0 dislike
I've put together a scene with a single particle in local space with a ribbon attached with a spawn metric based on distance.  The effect is to attach to a very swift attack animation in-game.  

When i test the effect in popcorn i get a smoothly curving ribbon but in-game it becomes faceted and reducing the spawn interval does not change the shape - it just makes the corners of the facets more busy as if the parent particle is jumping from point to point - perhaps in time with the animation frames.

To test this I added a second layer putting out hundreds of stationary billboard particles during the animation and they describe a smooth curve - suggesting the curve exists.

I then switched the billboards to a ribbon on that effect and got a smooth curved ribbon (but with less shape control options than the original).

Am I doing something wrong with the trail ribbon that is not translating into the game?


by gnoble (180 points)

1 Answer

0 like 0 dislike


We were going through all unanswered questions, and saw that yours slipped through and didn't get an answer at the time, sorry about that.

In case it's still of interest, even after 5 months (!), here goes:

the particles (regardless of if you're using ribbons or billboard renderers) definitely should be placed along the line that goes from the parent particle's previous frame position to the parent particle's current frame position.

so if they are all stacked at discrete locations along the path, each location matching, from what I understand, one frame, there's definitely something wrong.

Make sure you have your evolvers in that order:

Do not put the trail evolver inside the localspace evolver, and do not check its "LocalSpaceSpawn" property.

Here's what this setup produces when the effect moves along an animtrack backdrop at very high speed (and clamped at 30 fps to further emphasize each discrete frame (parent particle displayed as a purple billboard at the back):

Each little white dot inside the blue ribbon are each of the child particles that make up the ribbon.

This doesn't change wether you draw the particles with a ribbon or with a billboard renderer, the renderers cannot affect the computation of the particle fields (including Position), they'll only observe those values computed by the evolvers, and use them to display the particle.

If this is what you already observed, then it's normal behavior due to the per-frame discretization, the ribbon will draw a straight path between the position of the animation in the previous frame and its position in the current frame. But each individual particle should still be spread along that line.

if that's not the case, could you please send over a .pkkg containing your effect (right-click on the effect in the content browser > export to package) at support _at_ popcornfx _dot_ com, ideally with a repro project if you're using Unity or Unreal.

if that's the case and you don't want those lines to be straight, as the particles don't know about the animation, and can't guess the position it has between the two frames, it needs a more complex solution, involving getting the velocities of the emitter in the previous and current frame (potentially using attributes), and using these as tangents to manually interpolate the path in the child particle's spawn script, in the "PostEval" function. This would approximate the path between the two frames using a spline.
This is more complicated, but can be done, I can answer that in more details if you post a dedicated question.

Thanks !

(and sorry again for the delay in answering)

by Julien (35.3k points)