Teleport¶
Introduction¶
VIVE Wave™ implements the official blueprint function ResetOrientationAndPosition. It resets the tracking pose and makes sure the PlayerPawn will be at the exactly location and look forward the direction you assigned.
Use ResetOrientationAndPosition in teleport¶
Steps:
- Use SetActorLocation to move PlayerPawn to New Location
- Call ResetOrientationAndPosition with the function Option. It will make the tracking pose of HMD to be (0,0,0) if you select Position. I will make the forward orientation of HMD(Camera) to be identity if you select Orientation. And both functions take effect if you select PositionAndOrientation. Warning: Please skip the Yaw angle, the parameter takes no effect.
In this example, we only reset the Orientation.
Note
The ResetOrientationAndPosition is implemented by InAppRecenter blueprint function, so it compatible with InAppRecenter. The pose compensation will be overwritten if calling InAppRecenter.
Reference Sample¶
You can reference the level blueprint of plugin/Content/VRTestApp/Teleport_Test.umap