Server/Client Camera Spawns Different

In GameMode, you will spawn Player Controller(PC) when you LogIn GameMode, BeginPlay of PC will be call, then GameMode will see if you have enough player it then will call StartMatch which will call RestartPlayer to spawn the default Pawn for all PC. So basically you must call ViewTarget after GameMode call RestartPlayer, or can prevent the function to be called. You can add CanRestartPlayer in PlayerController script, it will prevent call RestartPlayer, or just simple put Timer to call set view after few second.

Other thing you can do it, when PC pawn DefaultPawn it will Possessed that Pawn so you can just override the PlayerController::Possessed() let the Super::Possessed finish first then call your SetViewTarget, btw all this thing will run on server side only.

2 Likes