I've been moving from Unity to Unreal and I'm finding it difficult to grasp the Raycast (Trace) logic of Unreal.
The use case I'm trying to implement at the moment is to trace a ray and check if I hit a specific set of objects or if there are other objects blocking the line of sight.
In Unity, I would use Raycast, define a new specific Layer, set the object layer to it, create a LayerMask with that Layer and Raycast. I consider this method to be performant as the use of layer masks provide a form of optimization and most importantly I'm guaranteed that if the ray hits an object than it's because its layer is part of the layer mask and if I'm using multiple layers I could simply check which layer the hit object has.
In Unreal it's been harder to understand what are the solutions that offer better performance and are easier to use. The C++ documentation for Line Trace (channel or object type) is very poor when comparing to Unity's.
Can anyone shed some light on how to move from the Unity logic to Unreal using the above use case as an example?