I’m not understanding why OutHitResult variable is needed to be reference.
Even if I don’t use reference like GetGrabbableInReach(FHitResult OutHitResult),
won’t function still return first hit object to OutHitResult variable and then to HitResult in Grab function?
but it makes editor crash, and I’m assuming HitResult are not getting the first hit object. Why?
Doesn’t variable needs to be same with parameter?
Why isn’t HitResult declared as reference?
Can anyone help me understand this?
Thanks in advance.