How to know the real world distance in ue4

Hello everyone! There are two questions annoyed me a lot.

  1. If I have two actors in unreal game world with cesium plugin, how can I know the real world distance(meters or kilometers anyway) between the two actors?
  2. How to create a specific length actor? For example, if I want to create a cube 5x5x5 meters(real world), how to set the cube’s length in unreal game world?

Thanks very much! :smiley:

Hi @JialingRichard,

Unreal units are metric by default. One unreal unit is equal to one centimeter, and likewise 100,000 unreal units equal one kilometer. For your cube example, the default cube that you can add to a scene from the Place Actors panel is 1 meter in size. If you scale the cube along any axis to “5.0”, it will be 5 meters long.

To get the distance between two actors, you can use a built in Unreal function like Get Distance To. I think that function returns the distance in Unreal units/centimeters, so to convert it to meters or kilometers you could divide the result by 100 or 100,000.

Let me know if you have further questions!
-Alex

Great! Thanks very much!

Check this UE5 video on YouTube:

Ta

J