Download

Reset VR camera position in c++

Hi, I have been working in unreal engine past 6 months and still know very little. I want to reset my Camera components location, so when I jump into a object I am sure that i am in 0,0,0 camera coordinates. Right now I am working on an example when I jump into a robot, I attach player character to robots bone socket. Everything works fine, however I want to be sure when I attach it I also reset location coordinates of camera, so player is actually in the middle.

When I checked blueprints, I saw that there is a blueprint function ResetRelativeTranform that I could use. However it is a scene component and I dont know how I can use it in c++.

Anyone knows how to reset Camera components location coordinates?

unrealforu.png
Thank you.
Sincerely,
Jakub Schinko