Line trace vs Sphere trace - which one has better performance?

In my case I use Multi Line Trace in a small area, but Multi Sphere trace would also do the job - so I wonder which one has less performance hit, line trace or sphere trace?

Any clues? :slight_smile: Probably the difference is small, but the more actors use this every tick, the more it matters…

I would assume sphere trace has a larger foot print since it is checking for hits in a larger area. Where as line trace is only checking a single point.

Would also like to know this, because i’ve grown fond of using sphere traces in a lot of circumstances.

The LineTrace is of course cheaper.
But the performance hit should be negligible if you keep them rare in one frame.

That makes good sense yes. Question is how much. Ie. i got some logic setup for matching fingers to objects when i grab them. With that i can end up firing 40 sphere traces at max in one frame. No question that’s quite a lot, but actually i haven’t been able to spot any significant hit on performance. So i realize we should keep them at minimum, but how bad are traces really? After having a talk with some people i dicovered that ie. the MovementComponent in the character itself also runs about 12 linetraces alone.