I am rewriting my blueprint in C++, and right now I am stuck on an issue with line tracing. BP has MultiLineTraceForObjects node, which returns all hits along the line trace. Equivalent of this in C++ should be LineTraceMultiByChannel(), BUT unfortunately, LineTraceMultiByChannel() stops any further hit testing after initial blocking hit was encountered, whereas the blueprint version keeps testing all the subsequent hits, even if the first one was blocking.
Basically, what I am trying to do is to line trace a grid of points against one specific actor in the level. I am deriving start and end positions of the line traces by bounding box of the objects. However, some other scene actors can be present in the level and be withing the bounds of the actor I am tracing against. In BP, I would just trace through such occluding actor, and iterate the hits until I find one which equals to my desired actor. In C++ I am unable to do that since LineTraceMultiByChannel() will simply refuse to trace beyond first blocking hit.
Any other ideas to solve this are appreciated too, but I will be calling this a lot, so inefficient solutions such as gathering all actors in the scene except one I am tracing against and then using that array as an actor exclusion parameter for line trace by object type is not really an option.
Thanks in advance.