Getting a null reference error from GetMyPlayerController in BP_Sub. Presumably this is due to the fact that PCs for other players can't exist on the client.
This was due to the fact that player controllers aren't available on client machines. Instead, we leveraged the new PlayerState class to handle everything for us.
Here's what I did:
Added IncrementKills and IncrementDeaths to PlayerState class.
On the server side, I got the instigator controller for the death (a parameter) and used it to get the corresponding player state. Since we're server-side, I simply incremented the kills via new functions.
3, After we reward the killer with points, we use Player State variable available for all pawns. the available functions for the current pawn. We can call this function later when there's death-by-suicide/accident.
Removed "Get VR Player State" and "Get My Player Controller" functions. These aren't needed anymore.
Getting a null reference error from GetMyPlayerController in BP_Sub. Presumably this is due to the fact that PCs for other players can't exist on the client.