«AI Move to» should follow the player if he goes into a Vehicle

My NPC’s follow the players-Character with this Code :

This works correct!

But if the FPS-Character (Player) goes into a Vehicle (like a Airplane or a Car) with this Code in the « Player Controll Class »

Then the NPC’s would not follow this New Vehicle (Aircraf/Car)!

Know’s someone the Solution for this?

How is your npc getting a target on your character? Pawn Sensing?
NPC won’t follow because he can’t see the actor as you hide it inside the game.

You will need to find a way to pass over the new target to AI when you enter the vehicle.

Hello DonBusso, my NPC follow me at every time! The NPC’s don’t have to see my FPS-Character.
I have tried to make an other Code if the FPS-Character is in an Vehicle like this:

But this Code did not work! But i think “Cast To Pawn” could be the right direction but i’am not shure.