Cannot convert FHitResult to FHitResult *
Wanting to use the function bool SetActorLocation(FVector, bool, FHitResult, ETeleportType), I'm running to the error of the question title.
The thing here is that the FHitResult has the pointer Symbol to it while being a function argument. How can I declare a variable (of type FHitResult*) to store it?
asked Nov 26 '18 at 07:53 AM in C++ Programming
You can declare your hit result like this:
A pointer is basically just a variable that stores a memory address. This is why you can pass the address of your hit result by using
& is the address-of-operator, which returns the memory address of your variable. So your function call might look somehow like this:
Hope that helps, let me know if you have any further questions.
Follow this question
Once you sign in you will be able to subscribe for any updates here