How to cast C++ APawn to a blueprint Pawn

So I have a player controller and inside of that player controller I want to get the controlled pawn, I found out that I can just call the APlayerController::GetPawn(), and that returns the controlled pawn, but the issue is that I have a Blueprint pawn called Troop, how do I cast the pawn that I get from calling GetPawn() to my blueprint type? I have not been able to find any sort of information on this, thanks in advance

im not sure i understand, there is literally a cast node that you can use

otherwise why not spawn it on the controller and then you’ll have a direct ref

C++ cannot be casted to Blueprint.
If u wanna call a blueprint function from c++, you can:

  • use interface
  • create a BlueprintImplementableEvent function in c++, then create the event in blueprint
  • call by UFunction reflection system