in my PlayerController I want to bind to a delegate of my player character. First I thought to put this in BeginPlay() of the PlayerController but I noticed that in my networking game, the clients will not possess a pawn in their PlayerController when BeginPlay() is called.
Then I chose to override the void OnPossess(APawn* InPawn) function, but this one is actually not called on the ListenServer, I assume because the possession happens before the game starts.
So is there any reliable function call that will be executed in the PlayerController on clients and on the server when the PlayerController owns a Pawn? Or do I need to check it in both functions and make sure I don’t initialize twice?
Thanks in advance