From 9ff422533f4f2ee48f0542d9e502bcd7758b8886 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9=20Straubmeier?= Date: Wed, 24 Nov 2021 10:19:55 +0100 Subject: [PATCH] Do test case fake IP initialization before login --- Facepunch.Steamworks.Test/AppTest.cs | 5 +++++ Facepunch.Steamworks.Test/NetworkingSockets.cs | 5 ----- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Facepunch.Steamworks.Test/AppTest.cs b/Facepunch.Steamworks.Test/AppTest.cs index 3b1e5fd..693abe2 100644 --- a/Facepunch.Steamworks.Test/AppTest.cs +++ b/Facepunch.Steamworks.Test/AppTest.cs @@ -46,6 +46,11 @@ namespace Steamworks Steamworks.SteamServer.Init( 252490, serverInit ); + // + // Needs to happen before LogOnAnonymous + // + SteamNetworkingSockets.RequestFakeIP(); + SteamServer.LogOnAnonymous(); } diff --git a/Facepunch.Steamworks.Test/NetworkingSockets.cs b/Facepunch.Steamworks.Test/NetworkingSockets.cs index 59dad4e..5e77c6f 100644 --- a/Facepunch.Steamworks.Test/NetworkingSockets.cs +++ b/Facepunch.Steamworks.Test/NetworkingSockets.cs @@ -57,8 +57,6 @@ namespace Steamworks SteamNetworkingUtils.DebugLevel = NetDebugOutput.Everything; SteamNetworkingUtils.OnDebugOutput += DebugOutput; - SteamNetworkingSockets.RequestFakeIP(); - var si = SteamNetworkingSockets.CreateRelaySocketFakeIP(); Console.WriteLine( $"Created Socket: {si}" ); @@ -131,9 +129,6 @@ namespace Steamworks // seems to prevent it returning null connections from ConnectNormal await Task.Delay( 2000 ); - Console.WriteLine( $"----- Requesting Fake IP.." ); - SteamNetworkingSockets.RequestFakeIP(); - Console.WriteLine( $"----- Creating Socket Relay Socket.." ); var socket = SteamNetworkingSockets.CreateRelaySocketFakeIP(); var server = socket.RunAsync();