PlayerController, Possess, Replication
I try to move the player specifics stuff to my PlayerController, but I have some trouble.
After possessing a pawn, I should be able to add and initialize a widget (through a blueprint call) and set a camera.
First, I tried this:
(OwnedShCharacter is initialized at BeginPlayingState(), which is called before APlayerController::Possess() ends.)
But the client will never run the Possess function at all. I also tried BeginPlayingState(). It did not have a valid character reference there.
I could not find a function which would be called on client after the effect of the Possession is replicated - it has to have a valid reference to the character in order to setup things. Is there any function like that?
Thanks for reading,
Call it manually. Create PC function like APlayerController::Client_Possess with UFUNCTION(Client) flag and call it inside Possess func on server.
answered Jun 18 '15 at 04:51 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here