This issue is happening on UE 4.13, and is currently driving me mad!
Workflow is quite simple:
- Hierarchical Instanced Static Mesh is spawned when level is loaded, with a static mesh and set object type to “SelectableFloors”.
- Left Click Mouse Button starts a LineTraceForObjects with the correct object type “SelectableFloors” in array > Everything works as expected, and the hierarchical instanced mesh is hit correctly (I can then grab the instance number from the hit results)
- Button “Page Down” sets said Hierarchical Instanced Static Mesh (and therefore all its instances) to ObjectType “WorldDynamic” and then set visibility to 0
- Left Click Mouse button still hits the now-invisible instance, despite it being set to “WorldDynamic” and not “SelectableFloors”. What’s funny is that if I grab the component’s object type directly from the HitResult, it does says “WorldDynamic”, so it definitely should have been ignored by the LineTraceForObjects set to “SelectableFloors” only.
Note that the same issue occurs if I use a custom trace channel instead of an object type. When I adapt the blueprint to trace channels rather than object type, the changed instance hit by the trace says that the same channel that it is looking for is set to “Ignore”.
Has anyone else encountered this issue? Somehow It looks like the data used by the LineTrace does not get updated if I change the collision object type or channel visibility at run-time.
Thanks for any assistance anyone could provide! I’d be very grateful!
Kind Regards,
Quentin