Is there a way to show the length of the selected point?

I want to make a tape measure function now, but I don’t know how. Can you create a function that shows the length between the selected point and the point?

Any of these will work:

And there’s probably half a dozen more. Some examples:

If you need something more substantial, consider including more details. Is this 2d / 3d, how are you selecting those points and how displaying distance should look / behave.

Thank you for your answer!
I’m going to make it in 3D, and I’m going to make it into a form where I can select points using motion controller. The distance indication only needs to be checked.
Thank you for the link!!

See if this snippet can get you started, you will need to adapt it to your needs, of course, but it could be a starting point:

You can copy the nodes from here:

The actor is a Pawn, with a Springarm + Camera and Text Render whose location is Absolute.

Thank you for your answer!
I’ll test it!!

It’s working fine!
However, it works on a computer.
I use this function in Magic Leap or Oculus.
I want to use it.
I’ve used it in Magic Leap, and there’s a problem.
Is there a way?

Change mouse cursor to Magic Leap Controller
I don’t know how to do it.

Never worked with magic leap. I assume that instead of a cursor one would use a trace (I might be wrong). How do you normally detect stuff with that controller?

It’s a matter of getting the world hit location.

Thank you for your answer!
Using the Magic Leap Controller instead of the mouse cursor,
You can use the laser pointer function to select objects.
If you haven’t used Magic Leap, it can be hard to understand.

It seems you get your hit from the raycast function in the first pic, no?