Convert relative location to world location?

I have searched all over but cannot find an answer on how to convert a relative location to a world location in blueprints…

This might be really simple and I am just missing it but can anyone help?

Thanks in advance!

The relative location of what to what? Of a component to its owning actor? Add the actors world location to the relative location of the component.

2 Likes

Like that?

2 Likes

Maybe this is a late response.


I Don’t Either know how to do it,but i trick it with some cheap cheat.when i want to add an item in specific place of the room but i want that item become an individual actor and & not a child actor i do it like this:

5 Likes

you’re an absolute life saver! I’ve been googling for a while and this workaround is the first actual solution I could find :smiley: Cheers!

Convert location from local to world:

FVector UKismetMathLibrary::TransformLocation(const FTransform& T, FVector Location)

Convert location from world to local:

FVector UKismetMathLibrary::InverseTransformLocation(const FTransform& T, FVector Location)
9 Likes

or just call TransformPosition(FVector Location) and InverseTransformLocation(FVector Location) on FTransform directly