PlayerState gets removed and Hosting / Joining session fails
From ShooterGame example, placing a level that the player and player controller are in between the front end menu and the map that the player travels to from hosting a session, causes the player state to be nuked or replaced, and causes issues with Hosting and Joining the session.
Even if the interim level overrides the player controller class and the game mode, this still occurs.
The interim level is loaded via a URL browse: GetEngine()->Browse
Then the player chooses to host a session and it 'seems' to work and the player travels to the host map.
When the other player travels to the interim level, and tries to 'search' for a hosted game, the session appears but the number of players shows as 0 ( zero ), even though the host is hosting it.
When the joining player joins that session, he fails to load into the level ( becomes stuck in the loading screen ).
The player state for the host becomes corrupt or deleted when they host a short time after entering the level. It seems to have something to do with trying to persist the player state from the last level.
Question: How can a session be cleanly hosted from an interim level in which a player pawn and controller exist, ,and not corrupt the player state of the player or non-player pawns, and how can the session be hosted and joined successfully?
asked Mar 24 '17 at 04:13 AM in C++ Programming
Here is the fix. In your Game Mode for your player base / interim level / player housing whatever it is....
Set this to false in the class constructor. bUseSeamlessTravel = false;
answered Mar 25 '17 at 04:35 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here