Server Travel crash?

I am trying to set up a basic multilayer game through steam. The host successfully creates a session and I succesfullly join that session.

In a JoinSessionCompleteDelegate function I created I call

if(Sessions->GetResolvedConnectString(DesiredResult, "GamePort", Connection))
{
       GetWorld()->ServerTravel(Connection);
}

When doing this I get a crash in ServerTravel saying ‘Short package names are not supported’ any idea why it would be doing this up until this point everything from creating the session to joining seemed to run smoothly.

Am I not supposed to pass this string directly into server travel? When passed into GetResolvedConnectString it seems to return steam.SteamID.Port

Any help would be great,

Pots3

Hi,

Try calling ClientTravel instead:

PlayerController->ClientTravel(Connection, TRAVEL_Absolute);

ServerTravel should only be called if you are the server and want connected clients to follow you.

Hope this helps!

What should I expect to happen when I call Client Travel?

The call doesn’t seem to fail as far I can tell and yet nothing happens to the state of the clients game should I not at least travel to the Hosts map?

Thanks!

I have had a look through the log files when this happens and came accross these lines…

[2014.09.03-15.00.18:871][170]LogNet:Warning: UNetConnection::Tick: Connection TIMED OUT. Closing connection. Driver: SteamNetDriver_0, Elapsed: 60.007988, Threshold: 60.000000, RemoteAddr: 76561198109124784:7777, PC: NoPC, Owner: No Owner
[2014.09.03-15.00.18:907][170]LogNet:Warning: Network Failure: PendingNetDriver[ConnectionTimeout]: UNetConnection::Tick: Connection TIMED OUT. Closing connection. Driver: SteamNetDriver_0, Elapsed: 60.007988, Threshold: 60.000000, RemoteAddr: 76561198109124784:7777, PC: NoPC, Owner: No Owner
[2014.09.03-15.00.18:936][170]LogNet: NetworkFailure: ConnectionTimeout, Error: 'UNetConnection::Tick: Connection TIMED OUT. Closing connection. Driver: SteamNetDriver_0, Elapsed: 60.007988, Threshold: 60.000000, RemoteAddr: 76561198109124784:7777, PC: NoPC, Owner: No Owner'
[2014.09.03-15.00.19:040][170]LogNet: UNetConnection::Close: Name: SteamNetConnection_0, Driver: PendingNetDriver SteamNetDriver_0, PC: NULL, Owner: NULL, Channels: 2, RemoteAddr: 76561198109124784:7777, Time: 2014.09.03-15.00.19
[2014.09.03-15.00.19:040][170]LogNet: UChannel::Close: Sending CloseBunch. ChIndex == 0. Name: ControlChannel_0

So I’m guessing I’m not setting something up properly and the connection is timing out resulting in the travel failing any ideas as to what I’m doing wrong? It says I have no Player Controller or Owner either does it mean my current player controller or is it trying to receive the hosts controller?

Thanks!

Still struggling with this am I missing something in my DefaultEngine.ini so far I have

[/Script/Engine.GameEngine]
!NetDriverDefinitions=ClearArray
+NetDriverDefinitions=(DefName="GameNetDriver",DriverClassName="OnlineSubsystemSteam.SteamNetDriver",DriverClassNameFallback="OnlineSubsystemUtils.IpNetDriver")

[OnlineSubsystem]
DefaultPlatformService=Steam

[OnlineSubsystemSteam]
bEnabled=true
SteamDevAppId=314000
GameServerQueryPort=27015
bRelaunchInSteam=false
GameVersion=1.0.0.0
bVACEnabled=1
bAllowP2PPacketRelay=true
P2PConnectionTimeout=90

[/Script/OnlineSubsystemSteam.SteamNetDriver]
NetConnectionClassName="OnlineSubsystemSteam.SteamNetConnection"
AllowDownloads=false

The problem seemed to be that unless you start the game from command line with ?listen somewhere in the command the game is never a listen server and is therefore never listening for data packets sent from the client for now I am just going to have to start my game as a listen server but surely there is a better way to do this?

Im running into the same issue now, did you ever sort this?

Yeah my issue seemed to be the host was never something known as a ‘Listen Server’ therefore it was never listening to Client connections. The Client as a result of this would then time out.

Try calling

GetWorld()->Listen(mapname);

With your current map name on the Server it seemed to solve the problem for me.

Hope this helps,

Pots3

I am having this same issue but I am not connecting to a steam service but the null one.
By Listen(mapname) you meant it the GameMode::RestartGame function?
Weird thing is the map that presents the problem previously worked and suddenly it started crashing on the client, I just added the ?Listen option as you suggested and it works.
Do we have an official answer about this problem?

Hey isaccvega-

The host must be setup as a listen server for the clients to be able to connect to it properly. As you and Pots3 mentioned, using ?Listen in the command line will do this or you can setup network settings/controls to be a listen server when not starting a game rather than connecting to one.

Cheers