Geometry collection does not always refresh collision mesh

I fixed it but it will take more resources to run,

After trying absolutely everything I could think off, I amended both lasers:

The one hitting with a static mesh moved with movement component is now also simulating physics. This fixed the problem with hitting actually visible pieces of the geo collection but it created other issues for my laser (I fixed those too but it’s not related to this issue so I won’t go through that here)

There is something weird happening in the geo collection.

  • If I set it to block hit event for my trace, I have the issue of, sometime, hitting the original shape.
  • If I set it to ignore Hit response, → same problem (the main level gets hit I guess but then the collision doesn’t always get refreshed).
  • But if I set it to ignore Hit response and set each individual pieces to another collision profile on Beguin play. Then, tracing for that new collision profile without hitting the original shape works. BUT this only works after the collection broke once!

Knowing this:
The other laser hitting using a line trace was hitting removed pieces, it was basically still hitting the original geo collection even after it broke. For this one, I had to do additional check to also trace specifically for the geo pieces if it hit the main shape (which could be invisible). So if the trace hit a geo collection, (at this point the hit is always accurate), I break the geocollection at impact location. Once broken, other laser hit use a different line trace that checks for the actual visible pieces (ignoring the main trace hit). I had to do a little more to support cases where more that 1 geo collection is hit but overall that how I fixed this.

Not amazing, performance won’t be as good but at least it can now be used for gameplay.

Good freaking luck if you have a similar issue :smiley:

I might check if UE 5.6 doesn’t have this issue but I’m almost done with the game so will see if worth it.

Cheers