Download

Instanced static meshes and collision

Is it not possible to have collision on instanced static meshes? I have a blueprint the generates a fence made up of instances for each section. I’m unable to get any collision working for them. I’ve tried setting collision everywhere I could think of with no luck. The static mesh has a collision box defined for it and I’ve tried the various options for collision (complex and simple). Nothing seems to work.

Hi Whammy,

I too am wondering this as I’ve tried and tried to have my instances trigger OnHit() and OnOverlap() to no avail.

Any insight into this issue would be appreciated.

Cheers.

Hi Whammy,

I’m using HISM and ISM actors in my current project and havent had any issues with collision at all. You mentioned that the mesh being instanced already has collision - what about the actor that holds the ISM? Did you check the collision setting on the actor spawning the ISM?

Things to check:

Drag the actual mesh to your level and check collision first (not instanced, just the actual mesh to your scene)
Change the mesh on your ISM actor and see if something as simple as a cube has collision
Make sure collision for the mesh and ISM actor is on “Block All” to see if collision is being triggered

If nothing works, post your Blueprint and mesh setup for us to take a look :slight_smile:

Hi MC1RScorpion,

This has worked for me as well. First make sure you enable “Generate Hit Events” on your ISM actor (the actor spawning the ISM meshes). Once you confirm Hit is being triggered (use a print statement), then you can break the hit and there will be an integer called Index (I believe). This integer represents the index of the ISM instance on the component.

So for example, You have 5 ISM meshes in your scene. The OnHit event will trigger when you hit ANY instance. However, the value “Index” will represent the index value of the specific instance being hit. So if you hit the first instance you placed, the value of Index will be 0.

From there, you can do whatever you want knowing which instance was hit.