How can I get the local velocity?

Thanks for your answer! But I’m not sure if I understand everything (sorry). Here is some of my old code which should an idea of what I’m trying to achieve:

  1. FVector VelVec = GetVelocity();
  2. float XVelocity = VelVec.X;
  3. FVector PlaneUp = GetActorUpVector();
  4. PlaneMesh->AddForce((PlaneUp)*XVelocity);

I am trying to get the planes forward speed on its own axis to turn the speed in to a slight lift. With my own old code it kind of worked. The problem was that the plane would just have to fly in the global x axis direction. So when the plane pitched straight down to get speed and new lift, it would be ignored because only the velocity in the global x axis direction was relevant.
I’m still very new to C++ so could you elaborate on your answer a bit and show me how implement the code you gave me in your answer? Thanks a lot!