establish trace hit point exit and distance

hi
i see i am rather terrible at framing this
can you know what is the distance of a trace hit within an object / actor
ie (distance between the trace hit entry location and) trace hit exit location within an object
in yet other words: you know the location of a trace hit; now, can you know the location of the trace hit exit and the distance of the trace within the body
how would you determine this
one vague possibility is to start a trace from the exact opposite side but it is not tthat straigh forward
regards

That’s the way to do it, afaik. It’s not that bad, I made this little tool:

  • it has two comps we can move around and fire a trace from Start to End:

  • initially, we fire a multi-line trace so it can penetrate:

And then trace back if multi-line did not hit anything else. Below, I’m measuring the spinning thingamajig:

Added some debug at the top so we can see the result.

In the script, the 2nd Branch’s True pin will need extra script for when you must handle other case scenarios - where the multi-line encounters another object we do not want to measure. Not included here since it’s unclear what we’re dealing with.


  • another way of handling the whole thing is to use a proper trace channel, so nothing else gets in the way
  • and yet another way is to use these:

image

if you know exactly which component you want to measure. Get its bound and trace from distances that are slightly larger. You still need to trace twice, but if you know start / end, it becomes trivial.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.