Sice Procedural Mesh results in missing faces sometimes

Hi!

I’ve been prototyping with Procedural Mesh Components and Slicing.
But every now and then I come across a slice with missing faces

The collision is generating fine, traces work as well. I checked with a two-sided material but the faces still sometimes just are still missing.

I also tried setting all sections of the procedural mesh component visibility to true after the slice (on both halves) but that did nothing.

I did notice it’s always the cap that will be missing not any other faces.
Here’s how I have the function setup:
image

I’ve tried searching here and on Reddit but I can’t seem to find any info on this so if anyone knows what could be the cause that would be much appreciated!

This is on version 5.2.1

I think I found a workaround, calling update mesh section seems to fix the visibility, but I then encountered an issue with some out of bound arrays within the mesh data so had to catch any empty arrays before calling it like this

So far working better, but I’ll keep looking into it

EDIT not sure this is actually helping (or having any effect at all) I checked the c++ code of the slice procedural mesh function on GitHub and it’s doing what I would expect (but I’m no expert) and could be related to the model I’m using.
Not sure what the requirements of the model used but maybe they need to be watertight or not use split normals, will need to continue looking into this.
I do wish the output of the slice function gave more data (like the index of the cap, maybe even the section data or if something couldn’t be created )

After months of looking into this, it was something pretty simple, I was using the location of the trace impact as the center of the slice plane
This was causing the cap not to generate at some angles.
Moving the center of the plane to inside or outside of the procedural mesh fixed the issue