Download

Get Velocity of VRPawn

Hello!

I am trying to get the velocity of my VR headset/ MotionControllerPawn in game. I am using the base VR template given by UE4.
I am scripting within my MotionControllerPawn BP (that’s the reference to *self *below, and I’m not sure that’s the reference I need to put there, but I’ve tried everything) which is also already in this template. It is composed of an Origin of VR and a camera.

Below is how I go about it.
My MovementsToTail function is linked to an Event Tick.
But this is only printing a speed of 0 forever no matter the movements I make.
Can someone help me?

My purpose is to start an event if the player crouches (therefore if the headset goes down on the z axis (that I would get instead of getting the velocity (but first things first))) - If the player crouches, the door opens. If you know another way to do so, I will be grateful.

Tanks for you help!